timesyncd on systems without battery

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Hello,
I run systemd on a NAS without internal-clock-holding battery, so I think that
the systemd-timesyncd sets the time to the last known value after restart and
syncs it from the network when on-line. Is it right?

Now, I have a shutdown timer unit, which powers the NAS off at the given time.
However, sometimes (about 50% of cases), when the device is powered-on, it
switches off immediately. When switched-on again, it boots as expected.

The question is, is there a way of fixing this issue? I have tried to add sleep
to skip to the next minute (ExecStart should be triggered one after another), but unsuccessfully.

Thank you,
DT


Here are the unit files.
timer:

[Unit]
Description=Poweroff the system on scheduled time

[Timer]
# Power off at the given time
_OnCalendar_=Mon,Tue,Wed,Thu,Fri *-*-* 01:10:00
_OnCalendar_=Sat,Sun             *-*-* 01:55:00

[Install]
WantedBy=timers.target

---
service:

[Unit]
Description=Poweroff the system

[Service]
Type=oneshot
ExecStart=/bin/sleep 80
ExecStart=/usr/bin/systemctl poweroff




_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux