Show us the cron job text ... sounds like improper redirect ... that stuff after the cron.php > this stuff here.
Consider doing this:
where ever your logs are kept .. like /var/logs/
touch /var/log/moodle-cron.log
Then the cron job becomes
/usr/bin/php /path/to/moodlecode/admin/cli/cron.php > /var/log/moodle-cron.log
Then run it from command line the same as above.
Check the log file: tail /var/log/moodle-cron.log
Can watch that log in realtime if you needed to:
tail -f /var/log/moodle-cron.log
Above will scroll @ frequency of the cron job.
'SoS', Ken
thank you
i fix it
the error was thar i call:
usr/local/bin/php -q/home/baseraadmin/public_html/courses/admin/cli/cron.php
or
/opt/cpanel/ea-php73/root/usr/bin/php -q/home/baseraadmin/public_html/courses/admin/cli/cron.php
or ..... i cant remember , i tried many
the correct is :
/usr/local/bin/ea-php73 /home/baseraadmin/public_html/courses/admin/cli/cron.php
in fact i do not know what are these commands
it is just a luck
i fix it
the error was thar i call:
usr/local/bin/php -q/home/baseraadmin/public_html/courses/admin/cli/cron.php
or
/opt/cpanel/ea-php73/root/usr/bin/php -q/home/baseraadmin/public_html/courses/admin/cli/cron.php
or ..... i cant remember , i tried many
the correct is :
/usr/local/bin/ea-php73 /home/baseraadmin/public_html/courses/admin/cli/cron.php
in fact i do not know what are these commands
it is just a luck
In reply to محمد نبيل
Re: Error for Cron job: "Error in argument 1, char 3: option not found "
by Visvanath Ratnaweera -
Mohammad, This is not about "Vps vs dedicated server". You should have started a new thread. I hope the moderator would split this new discussion. Gave it a new subject line already.
In reply to محمد نبيل
Re: Error for Cron job: "Error in argument 1, char 3: option not found "
by Visvanath Ratnaweera -
You might want to double check against https://docs.moodle.org/39/en/Cron.
In reply to Visvanath Ratnaweera
Re: Error for Cron job: "Error in argument 1, char 3: option not found "
by محمد نبيل -
in the doc
/usr/bin/php /.......
the ccommand that work is :
/usr/local/bin/ea-php73 /.....
---------------------------
the doc is wrong , or there is something i do not know?
/usr/bin/php /.......
the ccommand that work is :
/usr/local/bin/ea-php73 /.....
---------------------------
the doc is wrong , or there is something i do not know?
In reply to محمد نبيل
Re: Error for Cron job: "Error in argument 1, char 3: option not found "
by Ken Task -
Doc isn't wrong ... doesn't take into account Easy Apache .... nor any other multiple PHP version tool that providers might offer their customers. To document all providers and their differences is way beyond the scope of Moodle docs. We all pick our poisons (providers) and have to work on our on antidotes (adjustments from 'stock') in some cases.
But congrats to you ... in figuring it out!
'SoS', Ken
But congrats to you ... in figuring it out!
'SoS', Ken