We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on v1 candidate and expect to engage more with the community over the coming months. We are committed to open source, and we encourage contributors to help us build the future of Vesta.
Cron suddennly not run
Cron suddennly not run
Hello.
I have a problem with a CRON. He is suddennly not run. Two days ago all work's perfectly and I don't make a changes in the settings server, Vesta or CRON. Now i have in cron.log this error :
Aug 20 19:50:01 xshare cron[491]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:50:40 xshare cron[10027]: (CRON) INFO (pidfile fd = 3)
Aug 20 19:50:40 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:50:40 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:50:40 xshare cron[10027]: (CRON) INFO (Skipping @reboot jobs -- not system startup)
Aug 20 19:52:01 xshare cron[10027]: (admin) RELOAD (crontabs/admin)
Aug 20 19:52:01 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:52:01 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:53:01 xshare cron[10027]: (admin) RELOAD (crontabs/admin)
Aug 20 19:53:01 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:53:01 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:53:26 xshare cron[11498]: (CRON) INFO (pidfile fd = 3)
Aug 20 19:53:26 xshare cron[11498]: Error: bad day-of-month; while reading crontab for user admin
I try a few cron commands.. /php , wget , /use/bin/php and still dont work. Two days ago its work's..
Please help me find a solution :)
I have a problem with a CRON. He is suddennly not run. Two days ago all work's perfectly and I don't make a changes in the settings server, Vesta or CRON. Now i have in cron.log this error :
Aug 20 19:50:01 xshare cron[491]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:50:40 xshare cron[10027]: (CRON) INFO (pidfile fd = 3)
Aug 20 19:50:40 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:50:40 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:50:40 xshare cron[10027]: (CRON) INFO (Skipping @reboot jobs -- not system startup)
Aug 20 19:52:01 xshare cron[10027]: (admin) RELOAD (crontabs/admin)
Aug 20 19:52:01 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:52:01 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:53:01 xshare cron[10027]: (admin) RELOAD (crontabs/admin)
Aug 20 19:53:01 xshare cron[10027]: Error: bad day-of-month; while reading crontab for user admin
Aug 20 19:53:01 xshare cron[10027]: (admin) ERROR (Syntax error, this crontab file will be ignored)
Aug 20 19:53:26 xshare cron[11498]: (CRON) INFO (pidfile fd = 3)
Aug 20 19:53:26 xshare cron[11498]: Error: bad day-of-month; while reading crontab for user admin
I try a few cron commands.. /php , wget , /use/bin/php and still dont work. Two days ago its work's..
Please help me find a solution :)
Re: Cron suddennly not run
Whenever you post some error or you need help, it's really important for you to be as specific as possible and to provide information like the Operating System you're using, Vesta version, etc.
I suppose there is something wrong with the admin crontab. Run the following command to display the admin's crontab and copy/paste here the output, so we can see what's wrong. Omit any personal information (e.g. email address)
If using Ubuntu
If using CentOS
I suppose there is something wrong with the admin crontab. Run the following command to display the admin's crontab and copy/paste here the output, so we can see what's wrong. Omit any personal information (e.g. email address)
If using Ubuntu
Code: Select all
cat /var/spool/cron/crontabs/admin
Code: Select all
cat /var/spool/cron/admin
Re: Cron suddennly not run
Thank's for reply.
I have a Debian 8.5 with VestaCP 0.9.8-16
root@xshare:~# cat /var/spool/cron/crontabs/admin
MAILTO=[email protected]
15 02 02 * * sudo /usr/local/vesta/bin/v-update-sys-queue disk
15 00 00 * * sudo /usr/local/vesta/bin/v-update-sys-queue traffic
30 03 * * * sudo /usr/local/vesta/bin/v-update-sys-queue webstats
*/5 * * * * sudo /usr/local/vesta/bin/v-update-sys-queue backup
0 4 * * 1 sudo /usr/local/vesta/bin/v-backup-users
20 00 * * * sudo /usr/local/vesta/bin/v-update-user-stats
*/5 * * * * sudo /usr/local/vesta/bin/v-update-sys-rrd
5 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/auto_prune.cron.php >> /dev/null 2>&1
10 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/create_internal_notifications.cron.php >> /dev/null 2>&1
15 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/delete_redundant_files.cron.php >> /dev/null 2>&1
25 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/downgrade_accounts.cron.php >> /dev/null 2>&1
*/5 * * * * php /home/admin/web/mydomain/public_html/admin/tasks/process_file_queue.cron.php >> /dev/null 2>&1
0 1 * * * php /home/admin/web/mydomain/public_html/admin/tasks/create_email_notifications.cron.php >> /dev/null 2>&1
I have a Debian 8.5 with VestaCP 0.9.8-16
root@xshare:~# cat /var/spool/cron/crontabs/admin
MAILTO=[email protected]
15 02 02 * * sudo /usr/local/vesta/bin/v-update-sys-queue disk
15 00 00 * * sudo /usr/local/vesta/bin/v-update-sys-queue traffic
30 03 * * * sudo /usr/local/vesta/bin/v-update-sys-queue webstats
*/5 * * * * sudo /usr/local/vesta/bin/v-update-sys-queue backup
0 4 * * 1 sudo /usr/local/vesta/bin/v-backup-users
20 00 * * * sudo /usr/local/vesta/bin/v-update-user-stats
*/5 * * * * sudo /usr/local/vesta/bin/v-update-sys-rrd
5 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/auto_prune.cron.php >> /dev/null 2>&1
10 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/create_internal_notifications.cron.php >> /dev/null 2>&1
15 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/delete_redundant_files.cron.php >> /dev/null 2>&1
25 0 * * * php /home/admin/web/mydomain/public_html/admin/tasks/downgrade_accounts.cron.php >> /dev/null 2>&1
*/5 * * * * php /home/admin/web/mydomain/public_html/admin/tasks/process_file_queue.cron.php >> /dev/null 2>&1
0 1 * * * php /home/admin/web/mydomain/public_html/admin/tasks/create_email_notifications.cron.php >> /dev/null 2>&1
Re: Cron suddennly not run
It seems the second entry is wrong. Highlighted and underlined the mistake:
15 00 00 * * sudo /usr/local/vesta/bin/v-update-sys-queue traffic
You're asking for day 0 of the month, which does not exist. You can check your crontabs with http://crontab.guru/
Moreover I'm not sure if these php statements will work. I think you need to specify the full path to the executable /usr/bin/php (or wherever that is in your distribution) instead of just the php executable
15 00 00 * * sudo /usr/local/vesta/bin/v-update-sys-queue traffic
You're asking for day 0 of the month, which does not exist. You can check your crontabs with http://crontab.guru/
Moreover I'm not sure if these php statements will work. I think you need to specify the full path to the executable /usr/bin/php (or wherever that is in your distribution) instead of just the php executable
Re: Cron suddennly not run
I generate this cron with Vesta. Cron with /usr/bin/php don't work too.
All the Cron job don't work, not only this
All the Cron job don't work, not only this
Re: Cron suddennly not run
And all this cronjob work's 2 days ago. I not made any change for cron.
Re: Cron suddennly not run
Did you correct the mistake I noted on my previous message? If any job has an error, then none of them will execute.
Re: Cron suddennly not run
Now it's run! I made a change and now all cron's work perfectly!
Thanks a lot !
Thanks a lot !