My VPS runs a server, and the sql DB is very important to it. It occasionally corrupts (reason not yet known) and so I decided to put a daily backup regime in place, and installed automysqlbackup.
If I launch it as a user, it fails with
Code: Select all
Could not open required defaults file: /etc/mysql/debian.cnf
cron entries are in place, but are clearly not running as expected. How do I make this work automagically? I'm not massively familiar with the intricacies of cron.
/etc/crontab shows:
Code: Select all
# m h dom mon dow user command
17 * * * * root cd / && run-parts --report /etc/cron.hourly
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly )
52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly )
Code: Select all
#!/bin/sh
test -x /usr/sbin/automysqlbackup || exit 0
/usr/sbin/automysqlbackup
Please? Thank you in advance.