Date: Sat, 4 May 2013 20:20:01 GMT From: =?utf-8?B?SsOBS8OTIEFuZHLDoXM=?= <jako.andras@eik.bme.hu> To: freebsd-bugs@FreeBSD.org Subject: Re: conf/144804: ntpd(8) cannot resolve hostnames at system start Message-ID: <201305042020.r44KK18T065456@freefall.freebsd.org>
index | next in thread | raw e-mail
The following reply was made to PR conf/144804; it has been noted by GNATS.
From: =?utf-8?B?SsOBS8OTIEFuZHLDoXM=?= <jako.andras@eik.bme.hu>
To: bug-followup@FreeBSD.org, wilson.andrew.j@gmail.com
Cc:
Subject: Re: conf/144804: ntpd(8) cannot resolve hostnames at system start
Date: Sat, 4 May 2013 22:18:54 +0200
I have a very similar problem on 9-STABLE (built yesterday).
Messages at boot:
May 3 23:31:56 vpn-gw ntpd[715]: ntpd 4.2.4p5-a (1)
May 3 23:31:56 vpn-gw ntpd[716]: getaddrinfo: "reggae.eik.bme.hu" invalid host address, ignored
May 3 23:31:56 vpn-gw ntpd[716]: getaddrinfo: "swing.eik.bme.hu" invalid host address, ignored
May 3 23:31:56 vpn-gw ntpd[716]: getaddrinfo: "jazz.eik.bme.hu" invalid host address, ignored
May 3 23:31:57 vpn-gw kernel: re0: link state changed to UP
It seems that the problem is the lack of network connectivity, hence the
lack of a working resolver (I use recursive DNS servers running on other
machines) at ntpd startup. However, ntpq returns the correct IP
addresses (maybe it resolves them at the time I run ntpq, I don't know).
[goya@vpn-gw /usr/share/doc/ntp]$ ntpq -p
remote refid st t when poll reach delay offset jitter
==============================================================================
reggae.eik.bme. .INIT. 16 u - 512 0 0.000 0.000 0.000
swing.eik.bme.h .INIT. 16 u - 512 0 0.000 0.000 0.000
jazz.eik.bme.hu .INIT. 16 u - 512 0 0.000 0.000 0.000
[goya@vpn-gw /usr/share/doc/ntp]$ ntpq -np
remote refid st t when poll reach delay offset jitter
==============================================================================
152.66.116.122 .INIT. 16 u - 512 0 0.000 0.000 0.000
152.66.116.124 .INIT. 16 u - 512 0 0.000 0.000 0.000
152.66.116.120 .INIT. 16 u - 512 0 0.000 0.000 0.000
[goya@vpn-gw /usr/share/doc/ntp]$
Running '/etc/rc.d/ntpd restart' later resolves the problem.
In the freebsd-stable@ thread
http://lists.freebsd.org/pipermail/freebsd-stable/2011-October/064349.html
/etc/rc.d/netwait was suggested as a workaround.
I found with Google that OpenSUSE uses a much better (IMHO the correct)
approach: They have the 'dynamic' keyword for servers defined in
ntp.conf, causing ntpd to try to resolve the server's domain name later
also, not only at ntpd startup.
http://doc.opensuse.org/documentation/html/openSUSE/opensuse-reference/cha.netz.xntp.html#sec.netz.xntp.dynamic
(Don't know whether it's a newer ntpd, or their patched version, or a
completly different NTP software.)
Regards,
AndrĂ¡s
home |
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201305042020.r44KK18T065456>
