SELECT * FROM mdl_task_scheduled WHERE classname = ? [array ( 0 => '\\tool_recyclebin\\task\\cleanup_course_bin', )] -------------------------------- Query took: 0.00026392936706543 seconds. -------------------------------- -------------------------------- SELECT * FROM mdl_user WHERE id = ? AND deleted = ? [array ( 0 => '2', 1 => 0, )] -------------------------------- Query took: 0.00057196617126465 seconds. -------------------------------- -------------------------------- SELECT * FROM mdl_context WHERE contextlevel = ? AND instanceid = ? [array ( 0 => 50, 1 => '1', )] -------------------------------- Query took: 0.00023508071899414 seconds. -------------------------------- Execute scheduled task: Cleanup course recycle bin (tool_recyclebin\task\cleanup_course_bin) -------------------------------- SELECT * FROM mdl_tool_recyclebin_course WHERE timecreated <= ? [array ( 0 => 1520354665, )] -------------------------------- Query took: 0.0032570362091064 seconds. -------------------------------- [tool_recyclebin] Deleting item '703' from the course recycle bin ... -------------------------------- SELECT * FROM mdl_context WHERE contextlevel = ? AND instanceid = ? [array ( 0 => 50, 1 => '29', )] -------------------------------- Query took: 0.00018000602722168 seconds. -------------------------------- -------------------------------- SELECT id,category FROM mdl_course WHERE id = ? [array ( 0 => '29', )] -------------------------------- Query took: 0.00014615058898926 seconds. -------------------------------- ... used 3 dbqueries ... used 0.014083862304688 seconds Scheduled task failed: Cleanup course recycle bin (tool_recyclebin\task\cleanup_course_bin),Can not find data record in database table course. -------------------------------- SELECT * FROM mdl_task_scheduled WHERE classname = ? [array ( 0 => '\\tool_recyclebin\\task\\cleanup_course_bin', )] -------------------------------- Query took: 0.00019407272338867 seconds. -------------------------------- -------------------------------- UPDATE mdl_task_scheduled SET component = ?,classname = ?,lastruntime = ?,nextruntime = ?,blocking = ?,minute = ?,hour = ?,day = ?,month = ?,dayofweek = ?,faildelay = ?,customised = ?,disabled = ? WHERE id=? [array ( 0 => 'tool_recyclebin', 1 => '\\tool_recyclebin\\task\\cleanup_course_bin', 2 => '1505939410', 3 => 1521045865, 4 => '0', 5 => '*/30', 6 => '*', 7 => '*', 8 => '*', 9 => '*', 10 => 86400, 11 => '0', 12 => '0', 13 => '51', )] -------------------------------- Query took: 0.00028491020202637 seconds. --------------------------------