[systemd-devel] anacron timer for backup job to depend on network-online.target
arvidjaar at gmail.com
Sun Mar 1 19:26:21 PST 2015
В Sun, 01 Mar 2015 22:13:11 +0100
Thomas Koch <thomas at koch.ro> пишет:
> meta: is it ok to ask user questions on this list?
> I want my backup job to be triggered only, if my laptop is online. I've a
> service file and a timer file. Should I add a Wants= and After= dependency on
> network-online.target? To which file?
No, network-online.target is relevant only during boot and even then it
is best effort only. The simplest solution would be to add check of
"online state" to your backup script and gracefully fail if system is
> What is the effect, if the laptop is offline for a longer period? Will the backup
> jobs accumulate? Will a backup job trigger immediately when a connection is
> established and the job is overdue?
systemd does not know anything about network online state. What
software are you using to configure network?
> Regards, Thomas Koch
> Description=run obnam backup
> ExecStart=obnam backup
> Description=schedules obnam backup
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
More information about the systemd-devel