Rsnapshot Schedule Overlapping – Help with Backup Schedule

backuprsnapshot

I have to following configuration.

rsnapshot.conf

interval        halfhourly      4
interval        hourly  6
interval        twohourly       12
interval        daily   7
interval        weekly  4

crontab

0,30 * * * * /usr/bin/rsnapshot halfhourly >> /var/log/rsnapshot.halfhourly.log 2>&1
5 * * * * /usr/bin/rsnapshot hourly >> /var/log/rsnapshot.hourly.log 2>&1
10 */2 * * * /usr/bin/rsnapshot twohourly >> /var/log/rsnapshot.twohourly.log 2>&1
15 3 * * * /usr/bin/rsnapshot daily >> /var/log/rsnapshot.daily.log 2>&1
20 6 * * MON /usr/bin/rsnapshot weekly >> /var/log/rsnapshot.weekly.log 2>&1

Only halfhourly is running correctly now. hourly spits out this error:

rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot hourly
----------------------------------------------------------------------------
ERROR: Lockfile /var/run/rsnapshot.pid exists and so does its process, can not continue

To me it seems like my 5 min space between halfhourly and hourly is too small. Is this configuration crazy? I like having backups every thirty minutes, that will probably save my ass some day.

Please help me make a decent backup schedule, that doesn't clog up the system, but creates frequent enough backups.

Thank you.

Best Answer

rsnapshot/rsync can take a while just trying to figure out what files changed. So it's not really a good solution for really quick snapshots unless you're not dealing with many files.

You may want to look at options from this question. Although I'm not sure that question has a definitive solution for you.

For fast snapshots you'll need to move to a block level snapshot using btrfs or LVM. Neither of those solutions are ideal as btrfs is still experimental and LVM's snapshots aren't that robust and have issues of their own.