Cron advice needed.

MiCarl

Member
I've got a single database that I wish to back up every four hours business days. In cPanel I've got the following cron entry:

0 */4 * * 1-5 /usr/bin/mysqldump -uUSERNAME -pPASSWORD ACCOUNT_DB >/home/ACCOUNT/DBbackup

It does not seem to run. The command works if I enter in a shell.

Any suggestions for where to look to find out what's (not) happening?
 
Hi MiCarl,

I'd take a look at the cron log and see what it says. You'll find it at /var/log/cron

Hope that helps!
 
Thanks Dan,

I can't get to the log here at work because I don't have putty installed here (I do most of my system work at home).

I did enable email from the cron jobs and got this:
"Usage: mysqldump [OPTIONS] database [tables]"

I know that kind of error. Looking back at my command line I've got a % in the password and I'll bet cPanel is trying to interpret that to escape an ascii string.

I put the mysqldump command in a file and call that from the cron job. Will know in a few hours if that fixed it up.
 
Top