Talk:Rsnapshot

From ArchWiki
Latest comment: 15 June 2021 by Werkov in topic Unit files

Unit files

Regarding the Rsnapshot#Automation, you can use native systemd functionality to prevent race conditions: Create separate unit files for each level of backup and add After directives for the higher levels. For example, the unit file rsnapshot-weekly.service will contain After=rsnapshot-daily.service rsnapshot-hourly.service. Seems like a much cleaner solution (and it makes worth using systemd over cron) Flemingalexander (talk) 11:35, 19 August 2020 (UTC)Reply[reply]

Two points to this: a) the ordering should be reverse, i.e. longer interval runs before shorter interval (YMMV but check the rest of the wiki page), b) you can exploit dropins with just
cat >/etc/systemd/system/rsnapshot@weekly.service.d/40-order.conf <<EOD
[Unit]
After=rsnapshot@monthly.service
EOD
to avoid unit files replication. Werkov (talk) 08:51, 15 June 2021 (UTC)Reply[reply]

Automation section

It seems the user need to create the unit file for weekly, monthly, etc... So, the page needs to be edited --Rickxyz 16:01, 23 April 2018 (UTC)Reply[reply]