[ntp:questions] ntpd: time reset problem

Unruh unruh-spam at physics.ubc.ca
Tue Sep 15 18:39:47 UTC 2009


David Lord <snews at lordynet.org> writes:

>Unruh wrote:
>> David Lord <snews at lordynet.org> writes:
>> 
>>> Unruh wrote:
>>>> Steve Kostecke <kostecke at ntp.org> writes:
>>>>
>>>>> On 2009-09-14, David Lord <snews at lordynet.org> wrote:
>>>>>> Steve Kostecke wrote:
>>>>>>
>>>>>>> On 2009-09-14, David Lord <snews at lordynet.org> wrote:
>>>>>>>
>>>>>>>> Frank Elsner wrote:
>>>>>>>>
>>>>>>>> OT you also have rather a lot of sources specified and if just for a
>>>>>>>> single box it seems a bit excessive and could be trimmed to four or
>>>>>>>> five (I'd also guess some of those eight get same refid).
>>>>>>> Red Herring.
>>>>>> No, you missed the OT.
>>>>> ???
>>>>>>>> I've just been trying mobile broadband on a high latency connection
>>>>> [snip]
>>>>>>>> Then this weekend after reconfigured to use "burst" in server lines
>>>>>>> The use of "burst" against other peoples' time servers is generally
>>>>>>> considered to be abuse unless you have received permission to do so.
>>>>> [snip]
>>>>>> Anyway "burst" works and I now give myself permission to use
>>>>>> "burst" to set time from my own ntp servers which is as good
>>>>>> a compromise as any :-)
>>>>> Great.
>>>>>> Can you then suggest how it's at all possible for ntpd to be
>>>>>> of any use on a mobile connection with such high latency?
>>>>> Add to that the effects of aggressive power saving.
>>>>>> I just need to get something working that's significantly
>>>>>> better than wristwatch time.
>>>>> Perhaps you need to choose a different tool.
>>>> You could try chrony if you are running Linux or BSD. It might work
>>>> better under your conditions. Your horrible latencies are worrysome, and
>>>> make it hard to imagine how anything could work well. 
>> 
>>> Seems to be a feature of the Vodafone system here. Punch a hole
>>> through their network and latency will come down, that's why
>>> 'burst' works, just as explained in the documentation. Vodafone
>>> have port and nat translation but users aren't assigned a single
>>> ip address for a session so make several connections and it's
>>> possible several ip addresses will be used.
>> 
>>> Chrony gave a quicker convergence but doesn't seem to have
>>> equivalent to 'ntpd -q' and I'm converging from many seconds
>>> and even with the chrony equivalent of burst it takes too
>>> long compared to using 'ntpd -q' to set time reasonably close.
>> 
>> Put
>> initstepslew 10 client1 client3 client6
>> 
>> Which will use the three clients to determine the initial offset and if
>> greater than 10 sec will step rather than slew. 
>> ( change 10 to what you want).
>> 
>> Ie, it is like ntp with burst and -q only more configurable.

>I have 'initstepslew' but it doesn't actually appear to do
>the job that's needed and I've also tried 'burst n/m' and
>that's not seemed to help. John Hasler's makestep
>suggestion might be what's needed but using 'ntpd -q' to
>set the clock first does give required result, at least
>from last nights session.

>>> On Ubuntu I can't get both chrony and ntpd to coexist from
>>> package manager (conflicting packages).
>> 
>> You certainly do not want them both running at the same time. They will
>> battle each other. I do not know what other stuff could conflict.
>> chrony gives you the programs chronyd and chronyc and various docs and
>> init files. 

>I've had chrony installed along with ntpd on various
>systems for a long while and never considered having
>both running at once :-)

Obviously ubuntu decided that since both do the same thing and would be
in conflict if both were running at the same time, they will not allow
both to be installed. There is nothing about chrony or ntp which would
do this. 


>On Ubuntu it's made more difficult than it needs be as
>both default to running from startup. I've been trying
>to get radioclocks to work so need ntpd installed for
>those.  Anyway I'll try getting chrony installed
>standalone.

Lichvar now has a version of chrony whith shm support through which you
could run your radio clock. He also has a hack for ntpd with will use
any of its refclocks to feed data to chrony and thus get all of the ntp
support into chrony. (ntp runs but does nothing but feed refclock
readings to chrony)



>Radioclock idea was for when no dialup or lan was
>available but suffers same problem for mobile use that
>ntpd doesn't converge fast enough to be useful when
>several seconds off when started. It would be handy if
>refclock drivers had a step option but I can't see
>anything like that documented.

Again, chrony does, and yes it does work.



>Having said that I don't have the need for millisecond
>accuracies when there's no network but have had one
>major disaster when running a cleanup script and clock
>had at some time been badly off so masses of the wrong
>files were deleted :-(





More information about the questions mailing list