Other issues ... IF ... IF ... the cron job is using php-cli (command line) and not the php for the web.
So hoping you can find the php-cli ... one can via ssh:
As user on system, enter:
will show path like /usr/bin/php
Use whatever your server shows for a path with the next test.
IF that returns something like this:
PHP a version number (cli) blah, blah, blah ... the important part is the (cli).
That's the one you use with cron job.
In your screen shot it's after a reference to workshop allocation that machine language starts to appear ... actually I think it looks to be an issue of language involved in deleting. It's deleting modules in courses etc. that appear to use something other than English?
You can test the cron job via command line by doing the same thing as shown above (adjusting that path
to your moodle code).
A real life example:
[root@sos ~]# which php
[root@sos ~]# /usr/bin/php -v
PHP 7.2.31 (cli) (built: May 31 2020 16:18:31) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.2.31, Copyright (c) 1999-2018, by Zend Technologies
Moodle code in /var/www/html/moodle39/
[root@sos ~]# /usr/bin/php /var/www/html/moodle39/admin/cli/cron.php
The last things it does after workshop_allocation is ... trash clean up.
Execute scheduled task: Cleanup files in trash (core\task\file_trash_cleanup_task)
... started 23:25:54. Current memory use 51.7MB.
Deleting old draft files... ... started 23:25:54. Current memory use 51.7MB.
Deleting orphaned preview, and document conversion files... ... started 23:25:54. Current memory use 51.7MB.
... used 2 dbqueries
... used 0.0013871192932129 seconds
Scheduled task complete: Cleanup files in trash (core\task\file_trash_cleanup_task)
Ran 0 adhoc tasks found at Sat, 01 Aug 2020 23:25:53 -0500
Cron script completed correctly
Cron completed at 23:25:54. Memory used 51.6MB.
Execution took 1.602497 second
Did yours go beyond point and do something else ore did it just stop?
You might have to run your cron multiple times.
Up Arrow ... [ENTER] will execute again.
Alternative for cron cleaning up trash ...
Manually clean up trash ...
rm -fR *
Run cron again from command line. Might have to run cron from command line several times so server can catch up!!!