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.
Edit and add CRON return ERROR CODE 1
Edit and add CRON return ERROR CODE 1
Hello,
Every time i add or edit one cron task in VESTA action is saved but return always ERROR CODE 1.
I can see cron work successful but the error alert is annoying.
My server is ubuntu 18.04 and VestaCP is up to date ( Version:0.9.8 (amd64) Release:25) .
How i can debug this problem ?
Every time i add or edit one cron task in VESTA action is saved but return always ERROR CODE 1.
I can see cron work successful but the error alert is annoying.
My server is ubuntu 18.04 and VestaCP is up to date ( Version:0.9.8 (amd64) Release:25) .
How i can debug this problem ?
Re: Edit and add CRON return ERROR CODE 1
What I'd do is look in the vesta system log to find out the actual command that is run.
tail /var/log/vesta/system.log
That was one I added to my system and it looks a bit weird to me! Not sure what "autoupdate index.php reports" is doing in a field which is meant to contain a number!
Usage: v-add-cron-job USER MIN HOUR DAY MONTH WDAY COMMAND [JOB] [RESTART]
Anyway, so then I'd run that again manually from the command prompt to see if it gives me any more clues what the error was. In fact I'd use the correct format:
If there's no further information, I'd try running it with bash debug (warning ... a lot of output)
These are things I'd try on my own system. Use at your own risk!
tail /var/log/vesta/system.log
Code: Select all
v-add-cron-job 'admin' '30' '11' 'autoupdate index.php reports' 'autoupdate index.php reports' 'autoupdate index.php reports' '/home/admin/scripts/null.sh'
Usage: v-add-cron-job USER MIN HOUR DAY MONTH WDAY COMMAND [JOB] [RESTART]
Anyway, so then I'd run that again manually from the command prompt to see if it gives me any more clues what the error was. In fact I'd use the correct format:
Code: Select all
v-add-cron-job 'admin' '30' '11' '*' '*' '*' '/home/admin/scripts/null.sh'
Code: Select all
bash -x $VESTA/bin/v-add-cron-job 'admin' '30' '11' '*' '*' '*' '/home/admin/scripts/null.sh'