Bug#755722: [pkg-ntp-maintainers] Processed: Re: systemd: Warning on each reboot: Superblock last write time is in the future

Kurt Roeckx kurt at roeckx.be
Sun Jul 27 18:22:13 BST 2014


On Thu, Jul 24, 2014 at 04:30:48AM +0200, Jon Severinsson wrote:
> torsdag 24 juli 2014 00:02:09 skrev du:
> > reassign -1 systemd-sysv
> > thanks
> > 
> > I strongly disagree that ntpdate or ntp should be setting the RTC.
> > ntp doesn't know anything about the RTC, nor should it know
> > anything about it.  It's only concerned with the system clock.
> 
> ntp already do set the RTC (or more accurately, tells the kernel to do so), it 
> is only ntpdate that doesn't.

ntp does not tell the kernel to do so.  The kernel does so when 
it the clock is synchronized.  That is when the status !=
STA_UNSYNC.  But it is true that only ntpd sets this and not
ntpdate.  I'm not sure it's a good idea to set this in something
like ntpdate or since it might only runs once.  The current
implementation only seems to be doing this after an adjtimex()
call.

> > It seems only logical that the writing should also be done by
> > init, like it always has.
> 
> sysvinit has never read from, nor written to, the RTC, and only recently did 
> systemd start reading from the RTC, in order to get a reasonably accurate 
> system clock before starting any services that might rely on that.
> 
> Under sysvinit  hwclock from util-linux used to read the RTC and overwrite the 
> system clock partway through the boot, and then overwrite the RTC with the 
> system clock partway through the shutdown.

I don't care that init itself didn't read it.  But as part of the
boot controlled by init it did get read and it got written
during shutdown.  But now by systemd it's only in case op boot.

> As a result, hwclock would override the RTC on every clean shutdown, even 
> though dedicated HW are often less inaccurate than the software system clock. 

[citation needed]

> Additionally there was a risk of loosing an accurate time sync in the event of 
> an unclean shutdown.

I assume that in case of an unclean shutdown it didn't get
written, and so because the old system might in some cases not
write the time we're now never going to write it?

> Systemd upstream is generally not satisfied with this sort of half-measures, 
> and aims to get rid of them as soon as a better solution is made available.  
> As both the main ntp daemon and the new systemd-timesyncd daemon do write to 
> the RTC whenever they acquire an accurate time, the traditional band-aid at 
> shutdown where deemed unnecessary, and so they naturally removed it.

I don't even find timesyncd in Debian?  It seems to be new since
213?

> As suitable alternatives are available I do not find it warranted to override 
> upstream on this.  But if you are not interest in working on fixing the issue 
> from your side we can simply add a Breaks: on ntpdate in systemd instead.

That makes no sense at all.  ntpdate doesn't break anything.  If
you're not willing to fix it you should instead Depend on whatever
is needed not to break things.


Kurt




More information about the Pkg-systemd-maintainers mailing list