And in the comments you state you are checking the log in your cron job command located here:
If your command is this:
Then if the script is failing it will never be able to append output to The only way you can really debug this is to check the actual PHP command line error log; not a log you have arbitrarily created. By default the PHP command line interface does not log errors to a log file. I explain how to establish a PHP command line error log file here in this Stack Overflow post. It’s not that complicated and valuable to do in a case like this. But past any of this, is that I would recommend running that command manually from the command line with the full path to the script like this:
Just replace
Some scripts/applications require certain scripts to be run at a certain time to function properly. On Windows servers, you can set them up to run at certain times by creating a scheduled task (which is similar to running cron
jobs on Linux servers). Different versions of Plesk may have slightly different appearances, but the steps, buttons, and icons are the same. Creating a Scheduled Task in Plesk:You can set up Scheduled Tasks in Plesk by doing the following: 1) Log in to Plesk. 3) Click on the Add Task button. 4) Determine the appropriate type:
Removing a Scheduled Task in Plesk
NotesThe user you are logging in with should have enough permissions to create a scheduled task. Windows Shared customers automatically have permission, and the Admin user for Windows Dedicated Servers automatically has permission. Additional users created by the Admin on a Windows Dedicated Server may or may not have permission to set up scheduled tasks, depending on what permissions you give them. General helpCron Job From Plesk for Moodle
Hi I am using moodle 3.11.5+ version and I want to see the cron job schedule task thru plesk web edition. in the schedule task i hv set the script path (run a php script) to /var/www/vhosts/example.com/httpdocs/moodle/moodle/admin/cli/ and argument as cron:run cron style as ***** when i click run now, it run without error but moodle log shows no script runs. However if i use the remote access version it runs perfectly fine. please advise how to schedule on plesk Regards Rudraksh I don't run Plesk, but ... in what you've shared ... Why do you have 2 moodle directories in the path? /moodle/moodle/ ... maybe only one /moodle/ The other ... in moodlecode/admin/cli/ there are several .php scripts that will run only from command line. So in your cron setup, end it with a pointer to the php script the runs the cron ... thusly .../cli/cron.php 'SoS', Ken
How do I run a cron job in PHP?Cron Jobs with PHP and other File Type. PHP. Command to run a PHP5 cron job: php /home/username/public_html/cron.php. ... . Perl. Command to run a CGI cron job: perl /home/username/public_html/cgi-bin/file.pl.. SSH. Command to run a shell script cron job: /bin/sh /home/username/public_html/file.sh.. MySQL.. How do I run a cron job in Plesk Panel?Answer. Log into Plesk.. Navigate to Domains > example.com > Scheduled tasks or Tools & Settings > Scheduled Tasks.. Click Add task and set specify Run parameter to Cron style.. Fill in the Run text field with cron-style time syntax, for example: * */4 * * *. Fill in the Command text field with the cron command, for example:. How do I set up a scheduled task in Plesk?How to schedule a Customer scheduled task from Plesk UI:. Log in to Plesk.. Go to Websites & Domains > example.com > Scheduled Tasks > Add Task.. In the Command field put the full path to the script to be executed.. In the Run field set the the task execution time (an example is available here).. Click OK to save changes.. |