Re: [chrony-users] Fwd: Chrony malfunctioning at beaglebones

[ Thread Index | Date Index | More chrony.tuxfamily.org/chrony-users Archives ]


On Tue, Oct 6, 2015 at 11:53 AM, Miroslav Lichvar <mlichvar@xxxxxxxxxx> wrote:
> I have some code ready for this, but I realized if there is some
> interval in which the driftile timestamp is ignored, it will not work
> when the chrony RTC tracking (rtcfile) is enabled. When the RTC time
> is reset to its initial value and corrected by the previously measured
> offset, it may still be in the allowed interval before the driftfile
> modification time and it will be ignored. It would be basically
> restoring time of the previous boot.
>
> I'm not sure if we can make any assumptions on the raw RTC time if
> rtcfile is enabled, it's perfectly ok to keep it in 1970 and rely on
> chrony to correct the offset.
>
> So, should we always restore time from the modification timestamp of
> the driftfile with -s if it's in future and log a warning when the RTC
> time is ignored to make it easier for the user to debug any unexpected
> behavior?
>

Sorry for the delay. Had to read it a few times to understand. Chrony
is not so simple as we, users, like to think.

I see you already implemented it, anyway here go my comments, also
because I noticed I made a mistake previously.

I wrongly assumed that a rtc change by other OS to another timezone
should be respected. It shouldn't. If chrony detects the RTC is behind
its driffile by 8 hours, what does that mean? Nothing. Because Chrony
can never figure out what is the actual UTC time it means, only some
time from some random timezone.

So it is only the DST changes that can be more or less safely
inferred, and not so hardly:

IF driftfile over 1 hour ahead THEN restore time from driftfile

ELSE IF driftfile up to 1 hour ahead THEN IF not DST change at the end
of current driftfile hour, restore time from driftfile

ELSE restore time from RTC

In regard to rtcfile, I didn't check how you implemented it, but I
would say if the configuration have it, we could disregard this sanity
checks and always restore from the RTC as it is. Is really doesn't
make sense for the user to configure rtcfile if then he doesn't trust
the RTC.

Thanks,
Nuno

-- 
To unsubscribe email chrony-users-request@xxxxxxxxxxxxxxxxxxxx 
with "unsubscribe" in the subject.
For help email chrony-users-request@xxxxxxxxxxxxxxxxxxxx 
with "help" in the subject.
Trouble?  Email listmaster@xxxxxxxxxxxxxxxxxxxx.


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/