select * from indexation_server where `id` = "2" limit 1 SELECT `id` FROM `indexation_control` WHERE `type` = "1" and `status` = "1" and `list_id` = "2" LIMIT 1 INSERT INTO `indexation_control` (`type`, `list_id`, `server`, `action`, `status`, `start_time`, `last_action_ad`) VALUES ("1", "2", "index-ad","0", "1", "1500583467", "1500583467") select * from indexation_server where `id` = "2" limit 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583467 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583467 - 15)) and attempts < "1" and addition_time >= 1500583467 - 86400 and last_attempt <= 1500583467 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583467", status = "2", stream_id = "61", number_select = "0" WHERE `id` IN(54868,54867,54866,54865,54864,54863,54862,54861,54860,54859,54858,54857,54856,54855,54854,54853,54852,54851,54850,54849,54848,54847,54846,54845,54844) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583467' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583473 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583473 - 15)) and attempts < "1" and addition_time >= 1500583473 - 86400 and last_attempt <= 1500583473 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583473", status = "2", stream_id = "61", number_select = "1" WHERE `id` IN(54843,54842,54841,54840,54839,54838,54837,54836,54835,54834,54833,54832,54831,54830,54829,54828,54827,54826,54825,54824,54823,54822,54821,54820,54819) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583473' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583479 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583479 - 15)) and attempts < "1" and addition_time >= 1500583479 - 86400 and last_attempt <= 1500583479 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583479", status = "2", stream_id = "61", number_select = "2" WHERE `id` IN(54818,54817,54816,54815,54814,54813,54812,54811,54810,54809,54808,54807,54806,54805,54804,54803,54802,54801,54800,54799,54798,54797,54796,54795,54794) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583479' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583485 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583485 - 15)) and attempts < "1" and addition_time >= 1500583485 - 86400 and last_attempt <= 1500583485 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583485", status = "2", stream_id = "61", number_select = "3" WHERE `id` IN(54793,54792,54791,54790,54789,54788,54787,54786,54785,54784,54783,54782,54781,54780,54779,54778,54777,54776,54775,54774,54773,54772,54771,54770,54769) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583485' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583491 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583491 - 15)) and attempts < "1" and addition_time >= 1500583491 - 86400 and last_attempt <= 1500583491 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583491", status = "2", stream_id = "61", number_select = "4" WHERE `id` IN(54768,54767,54766,54765,54764,54763,54762,54761,54760,54759,54758,54757,54756,54755,54754,54753,54752,54751,54750,54749,54748,54747,54746,54745,54744) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583491' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583497 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583497 - 15)) and attempts < "1" and addition_time >= 1500583497 - 86400 and last_attempt <= 1500583497 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583497", status = "2", stream_id = "61", number_select = "5" WHERE `id` IN(54743,54742,54741,54740,54739,54738,54737,54736,54735,54734,54733,54732,54731,54730,54729,54728,54727,54726,54725,54724,54723,54722,54721,54720,54719) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583497' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583503 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583503 - 15)) and attempts < "1" and addition_time >= 1500583503 - 86400 and last_attempt <= 1500583503 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583503", status = "2", stream_id = "61", number_select = "6" WHERE `id` IN(54718,54717,54716,54715,54714,54713,54712,54711,54710,54709,54708,54707,54706,54705,54704,54703,54702,54701,54700,54699,54698,54697,54696,54695,54694) UPDATE `indexation_control` SET `img_check` = img_check + 25, `last_action_ad` = '1500583503' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583509 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583509 - 15)) and attempts < "1" and addition_time >= 1500583509 - 86400 and last_attempt <= 1500583509 - 5 order by addition_time DESC, id DESC limit 25 UPDATE img_download SET attempts = attempts + 1, last_attempt = "1500583509", status = "2", stream_id = "61", number_select = "7" WHERE `id` IN(54693,54692,54691,54690,54689,54688,54687,54686,54685,54684,54683) UPDATE `indexation_control` SET `img_check` = img_check + 11, `last_action_ad` = '1500583509' WHERE id = '61' LIMIT 1 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 SHOW PROCESSLIST select count(id) from img_download where status = "2" and last_attempt > 1500583510 - 15 and stream_id = "61" SELECT `id`, `url`, `ad`, `source_name`, `crop_img`, `height_img`, `name` FROM `img_download` where (status = "0" or (status = "2" and last_attempt < 1500583510 - 15)) and attempts < "1" and addition_time >= 1500583510 - 86400 and last_attempt <= 1500583510 - 5 order by addition_time DESC, id DESC limit 25 SELECT action FROM indexation_control WHERE id = "61" and status = "1" LIMIT 1 UPDATE indexation_control SET `status` = '0', last_action_ad = '1500583515' WHERE id = '61' and status = '1' LIMIT 1