[ntp:questions] What happens if ntp server unavailable at start up?

Unruh unruh-spam at physics.ubc.ca
Fri Sep 12 13:31:45 UTC 2008


Martin Burnicki <martin.burnicki at meinberg.de> writes:

>Bill,

>Bill Unruh wrote:
>> A question has arisen in another group-- What happens if, when ntp starts
>> up, the remoter server is unavailable ( eg no DNS or no connection)?
>> This is highly likely to be the case for a laptop for example, where the
>> connection with the local network is only brought up by the user after a
>> while, or on wakeup from a power outage when the net may be unstable or
>> the router be out when ntp comes up.
>> 
>> If a server disappears in a running ntp, ntp keeps trying, backing off on
>> the poll interval after a while. But what does ntp do if on the first try
>> to a server, there is no response, or if the dns is down. Does it forever
>> scrub that server? (that seems to be what happnes-- if so why?) or does it
>> do the same thing as if the server disappears after a while (keep trying
>> with increasing poll intervals)?
>> 
>> I notice that there is a keyword dynamic which is not yet implimented but
>> which seems to imply the second option.

>The keywaord "dynamic" had been introduced IIRC in 4.2.4. It lets ntpd retry
>if a server can not be reached initially.

>However, since the behaviour with the "dynamic" keyword is what users would
>normally expect ntpd to do I have proposed to make the "dynamic" behaviour
>the default and obsolete the "dynamic" keyword. This has been done in
>current ntp-dev and int ntp-stable 4.2.4p5. 

>For details see:
>https://support.ntp.org/bugs/show_bug.cgi?id=841

That one seems have degenerated into a slangfest about how bugs should be
handled. It is not at all clear from that discussion that the bug has in
fact been fixed.

>https://support.ntp.org/bugs/show_bug.cgi?id=987

>> Also what happens to ntpd if it has no servers whatsoever, not even a
>> local one? Does it keep running, doing nothing, or does it exit?

>What do you mean by "has no servers"? "Has no servers configured", or "has
>no servers reachable"? In the latter case ntpd 4.2.4p5 just retries until a
>network interface becomes available.

Sounds great. So, let me say I have pool.ntp.org as a server. when my
system comes up (a desktop) the network interface is there, but the dns
server is still dead, and the gateway is still dead. Ie, no address for
pool can be gotten from dns. Does the system keep trying or does it give up
on that server?


>Martin
>-- 
>Martin Burnicki

>Meinberg Funkuhren
>Bad Pyrmont
>Germany




More information about the questions mailing list