[ntp:questions] Re: New to NTP

Per Hedeland per at hedeland.org
Sat Sep 20 10:31:24 UTC 2003

In article <%QMab.1222$0x5.225968 at stones.force9.net> "Ian Gibbons"
<ian at BEYONDmywits-end.co.uk> writes:
>"Per Hedeland" <per at hedeland.org> wrote in message
>news:bk5evd$20ae$4 at hedeland.org...
>> In article <bD69b.5613$vX3.682595 at wards.force9.net> "Ian Gibbons"
>> <ian at BEYONDmywits-end.co.uk> writes:
>> >
>> >Tried that didnt work. Infact its actually using 'ntpd', but for some
>> >it still binds to all interfaces, then again to them individually so as
>> >take up three lines on netstat -a.
>> >Why is it doing this? It looks crazy and its mildly annoying also, as I
>> >keep my netstat list as clean as possible.
>> Binding to all IP addresses individually is the only way (with the
>> standard IPv4 socket interface) to find the destination address of
>> incoming UDP packets - and ntpd needs to do that to be able to send
>> reply packets with that address as source. BIND does the same thing
>> (by default).
>Cheers for the explaination. Is there not a way you can force it to use a
>particular interface/ip ?

Not as far as I know. It should supposedly not bind to "virtual" IP
addresses unless given the -L flag, but I seem to remember that this
only works on Linux or somesuch.

>As simply having it bind to eth0's IP would be great.

It needs to bind to the wildcard address too, to receive broadcasts.
Which in your case leaves only the loopback address, which seems
pointless to remove, and it will probably deprive you of handy things
like 'ntpq -p localhost'. Now if you had a few hundred virtual IP
addresses for web hosting that ntpd insisted on binding to, there might
be something to be concerned with. Or if you absolutely did not want it
to bind to (or rather listen to queries on) the address of certain
physical interfaces on a multi-homed host, for whatever reason.

--Per Hedeland
per at hedeland.org

More information about the questions mailing list