Bug#824707: systemd: I get fsck's every other boot: due to systemd-timesyncd not updating hwclock?
Manuel Bilderbeek
manuel.bilderbeek at gmail.com
Thu May 19 20:30:10 BST 2016
Hi,
Thanks for taking interest in this annoying problem. Today I again got
an fsck at boot...
On 18-05-16 23:35, Michael Biebl wrote:
> fsck.ext[234] should no longer run an fsck because of that.
> Which version of e2fsprogs have you installed?
Should be latest in testing:
ii e2fsprogs 1.43~WIP.2016.03.15-2
amd64 ext2/ext3/ext4 file system utilities
> What are the contents of /etc/adjtime?
$ cat /etc/adjtime
0.000000 1463602260 0.000000
1463602260
UTC
> In any case, that sounds like a e2fsprogs related problem.
Anything else I can do to gather more information to find the source of
the problem?
On 19-05-16 00:03, Martin Pitt wrote:
> timesyncd does *not* write to the hw clock directly. The kernel has
> done that by itself now every 11 minutes for a fair while now, if the
> hw clock is in UTC. (If it's not, then timesyncd tells the kernel to
> not sync). See manager_adjust_clock() in
>
>
https://github.com/systemd/systemd/blob/master/src/timesync/timesyncd-manager.c#L314
How can I tell that the kernel should sync it?
Perhaps this:
$ timedatectl
Local time: do 2016-05-19 21:21:30 CEST
Universal time: do 2016-05-19 19:21:30 UTC
RTC time: do 2016-05-19 19:21:30
Time zone: Europe/Amsterdam (CEST, +0200)
Network time on: yes
NTP synchronized: yes
RTC in local TZ: no
FYI, this is the log entry of today's boot:
mei 22 12:37:10 sonata systemd-fsck[343]: /dev/sda1 has gone 4385 days
without being checked, check forced.
... well at least now it logs why it's doing the fsck...
mei 22 12:41:25 sonata systemd-fsck[343]: /dev/sda1: 858066/3055616
files (7.5% non-contiguous), 8046780/12207384 blocks
mei 22 12:41:26 sonata systemd[1]: Started File System Check on /dev/sda1.
mei 22 12:41:26 sonata systemd[1]: Mounting /media/olddisk1...
mei 22 12:41:26 sonata systemd[1]: Mounted /media/olddisk1.
mei 22 12:41:26 sonata kernel: EXT4-fs (sda1): mounted filesystem with
ordered data mode. Opts: (null)
mei 22 12:41:26 sonata systemd-fsck[348]: /dev/sda6 has gone 4385 days
without being checked, check forced.
mei 22 13:01:33 sonata systemd-fsck[348]: /dev/sda6: 974019/30523392
files (8.8% non-contiguous), 114529416/122069894 blocks
mei 22 13:01:34 sonata systemd[1]: Started File System Check on /dev/sda6.
mei 22 13:01:34 sonata systemd[1]: Mounting /media/olddisk6...
...
mei 22 13:02:02 sonata systemd[1420]: Startup finished in 18ms.
mei 22 13:02:02 sonata systemd[1]: Started User Manager for UID 1000.
mei 19 18:54:52 sonata systemd[1]: Time has been changed
mei 19 18:54:52 sonata systemd[1420]: Time has been changed
mei 19 18:54:52 sonata systemd[1175]: Time has been changed
mei 19 18:54:52 sonata systemd-timesyncd[478]: Synchronized to time
server 83.98.201.134:123 (2.debian.pool.ntp.org).
mei 19 18:54:52 sonata systemd[1]: apt-daily.timer: Adding 4h 20min
45.246388s random time.
I don't know what's happening, but my RTC tends to get ahead A LOT.
Although I can't match the 4385 days with the 3 days difference I saw in
this boot log.
Oh, wait, I can... check the start of the log:
-- Logs begin at ma 2028-05-22 12:37:10 CEST, end at do 2016-05-19
21:22:23 CEST. --
Looks like I need to have systemd-timesync run *before* systemd-fsck!?
--
Grtjs, Manuel
PS: MSX FOR EVER! (Questions? http://faq.msxnet.org/ )
PPS: Visit my homepage at http://manuel.msxnet.org/
More information about the Pkg-systemd-maintainers
mailing list