context_cleanup_task failing

Re: context_cleanup_task failing

by Josiah Carberry -
Number of replies: 0

I found the cron job output. Here is the relevant bit. It is the first task in the log, and all the other tasks completed normally.

Execute scheduled task: Cleanup contexts (core\task\context_cleanup_task)
... started 17:00:01. Current memory use 3.1MB.
... used 27 dbqueries
... used 0.018734931945801 seconds
Scheduled task failed: Cleanup contexts (core\task\context_cleanup_task),Cannot read file. Either the file does not exist or there is a permission problem.
Debug info:
/blahblah/moodledata/filedir/0b/9e/0b9e9d72abc2164850351a25c12d439e9747a40b
Backtrace:
* line 298 of /lib/filestorage/stored_file.php: call to stored_file->update()
* line 2478 of /lib/filestorage/file_storage.php: call to stored_file->delete_reference()
* line 344 of /lib/filestorage/stored_file.php: call to file_storage->import_external_file()
* line 1027 of /lib/filestorage/file_storage.php: call to stored_file->delete()
* line 5580 of /lib/accesslib.php: call to file_storage->delete_area_files()
* line 5613 of /lib/accesslib.php: call to context->delete_content()
* line 6016 of /lib/accesslib.php: call to context->delete()
* line 47 of /lib/classes/task/context_cleanup_task.php: call to context_helper::cleanup_instances()
* line 75 of /lib/cronlib.php: call to core\task\context_cleanup_task->execute()
* line 81 of /admin/cron.php: call to cron_run()