1

Yesterday I've configured rsnapshot on a debian 9 machine, but the cron's I've set for the backups in /etc/cron.d/rsnapshot are not being executed.

Also, after I save & close the /etc/cron.d/rsnapshot it doesn't say it installed the new crontab.

How can I find out why it's not being executed? I've already done some searching on this website and have found the following things:

  • There are no entries in /var/mail
  • Right permissions + owner for /etc/crontab

Also the cron process is running:

ps aux | grep cron root 364 0.0 0.0 29664 2880 ? Ss Oct12 0:05 /usr/sbin/cron -f 

The cron is set as following:

0 */4* * * root /usr/bin/rsnapshot hourly 

Any suggestions on how I can find out why the crons are not being executed? I've already tried executing the command manually (this works) and have also tried nano and vim while editing and closing the rsnapshot cron file.

1 Answer 1

2

You miss one space in the cron record. I should be like this:

0 */4 * * * root /usr/bin/rsnapshot hourly 
4
  • Sorry for that, I've corrected it. However it still doesn't say it saved the new crontab once I close the file. Commented Nov 6, 2018 at 8:22
  • @user2191227, you will get this text if you exec crontab -e and not when you use cron.d directory Commented Nov 6, 2018 at 8:26
  • Ah alright thanks for clearing that up, I'll wait and see if it worked out Commented Nov 6, 2018 at 8:36
  • 1
    The cron is now running, thanks Romeo for your help! Commented Nov 6, 2018 at 18:08

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.