[ntp:questions] ntp.conf true and prefer option for server command

suhas manjunath suhasmanjunath32 at gmail.com
Mon Jan 16 07:15:10 UTC 2017


Hi,



I was trying to configure ntp servers in my ntp.conf file. Below is the
snippet of conf file.



restrict -4 IP1 kod nomodify notrap nopeer noquery

server -4 IP1 prefer true iburst minpoll 4 maxpoll 6

restrict -4 IP2 kod nomodify notrap nopeer noquery

server -4 IP2 iburst minpoll 4 maxpoll 6

restrict -4 IP3 kod nomodify notrap nopeer noquery

server -4 IP3 iburst minpoll 4 maxpoll 6



As per my understanding if prefer true option is used with IP1, it'll
escape/survive select and cluster algorithm, and will always be selected as
preferred server but it is not working it is taking IP3 as a preferred
server. Could anyone please explain it why?



Also to add more info: if I delete IP2 and IP3 forwarder then it will take
IP1 has preferred forwarder.



Output of ntpq –pn:

# ntpq -pn

     remote           refid      st t when poll reach   delay   offset
jitter

==============================================================================

IP1                        IP4         5 u    1   64  377    0.337
-14.852   0.913

+IP2                LOCAL(0)    7 u   55   64  377    0.290    0.224   1.286

*IP3                     IP5          4 u   65   64  377  159.282
-13.244   1.914

127.127.1.2     .LOCL.   10 u 1969   16    0    0.000    0.000   0.000





Thanks,

Suhas T M


More information about the questions mailing list