Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #181885

Re: NTP.conf pool vs server

From Greg Wooledge <wooledg@eeg.ccf.org>
Newsgroups linux.debian.user
Subject Re: NTP.conf pool vs server
Date 2017-06-07 17:00 +0200
Message-ID <tPKBd-7Z0-37@gated-at.bofh.it> (permalink)
References <tPJ2q-77i-15@gated-at.bofh.it> <tPKhP-7Rr-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Jun 07, 2017 at 10:35:23AM -0400, Gene Heskett wrote:
> Begin rant:
> 
> From someone who is currently battling a fresh jessie install that didn't 
> even come with ntpdate installed, and which using the above format 
> in /etc/ntp.conf is still about 12 hours off on an rpi-3.

The ntpdate package has been deprecated for some time now, in Debian.
You don't need it.  Simply install the ntp package, and configure the
/etc/ntp.conf file (which admittedly is not clearly documented).

Current versions of Debian have folded the ntpdate functionality into
ntp.  The /etc/default/ntp file has (or should have!) this:

NTPD_OPTS='-g'

This starts ntpd with the -g option, which tells it that it's allowed
to slam the clock forward or backward exactly once when it starts up,
mimicking what ntpdate used to do.

> Installing ntpdate and attempting to start it gets me a no servers found 
> message, yet they are defined as discussed above, and the network is 
> fully accessible to all other forms of communication.  

Sounds like something is misconfigured, though we can't tell what it is
without additional info.

> But a manpage that actually tells us how to do that must be sick bird, 
> because its not been written yet.  Man page writers please get real, and 
> tell us how to do something like getting our home networks all 
> synchronized to our routers which can then broadcast it to the rest of 
> our network.

On the machine that you want to act as your local network's time server:

server 0.debian.pool.ntp.org iburst
server 1.debian.pool.ntp.org iburst
server 2.debian.pool.ntp.org iburst
server 3.debian.pool.ntp.org iburst

And make sure you didn't change the lines under the comment that says
"By default, exchange time with everybody, but don't allow configuration."

On your other machines:

server your.time.server

That's basically it.  Make sure the hostname is resolvable.  If you have
issues with name resolution not being available sometimes, then you might
want to add your.time.server to /etc/hosts.

To verify that things are running, use ntpq -p:

svr5:~$ ntpq -p
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
-104.245.32.240  162.213.2.253    2 u  776 1024  377   80.415   -8.341   0.239
*clocka.ntpjs.or 18.26.4.105      2 u  250 1024  377    9.780    0.361   0.556
+up2.com         195.219.14.21    2 u  490 1024  377   31.761   -1.224   0.474
+jarvis.arlen.io 17.253.2.253     2 u  477 1024  377   36.764   -2.368   4.547

And that's why you use multiple public time servers -- they aren't very
accurate, so you need lots of them.  The daemon can decide which ones
to ignore, and so on.

The output of this -p thing is not documented, so you have to guess what
it means.  I think the "-" in column 1 means "this server sucks, so I'm
not really paying attention to it", and "+" means "pretty good", and "*"
means "this is my favorite".  But that's just a guess.  There's nothing
in the ntpq man page about it at all.

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

NTP.conf   pool vs server ray <ray@aarden.us> - 2017-06-07 15:20 +0200
  Re: NTP.conf   pool vs server Greg Wooledge <wooledg@eeg.ccf.org> - 2017-06-07 15:30 +0200
    Re: NTP.conf   pool vs server Gene Heskett <gheskett@shentel.net> - 2017-06-07 16:50 +0200
  Re: NTP.conf   pool vs server Gene Heskett <gheskett@shentel.net> - 2017-06-07 16:40 +0200
    Re: NTP.conf   pool vs server Greg Wooledge <wooledg@eeg.ccf.org> - 2017-06-07 17:00 +0200
    Re: NTP.conf   pool vs server Darac Marjal <mailinglist@darac.org.uk> - 2017-06-07 17:00 +0200
      Re: NTP.conf   pool vs server Greg Wooledge <wooledg@eeg.ccf.org> - 2017-06-07 17:10 +0200
        Re: NTP.conf pool vs server Joshua Schaeffer <jschaeffer0922@gmail.com> - 2017-06-07 17:30 +0200
          Re: NTP.conf pool vs server Greg Wooledge <wooledg@eeg.ccf.org> - 2017-06-07 17:50 +0200
        Re: NTP.conf   pool vs server Henrique de Moraes Holschuh <hmh@debian.org> - 2017-06-07 18:10 +0200
      Re: NTP.conf   pool vs server Darac Marjal <mailinglist@darac.org.uk> - 2017-06-07 17:20 +0200
      Re: NTP.conf   pool vs server Gene Heskett <gheskett@shentel.net> - 2017-06-08 01:10 +0200
        Re: NTP.conf   pool vs server Darac Marjal <mailinglist@darac.org.uk> - 2017-06-08 14:30 +0200
          Re: https_port "Adiel Plasencia Herrera" <adielp@estereocentro.icrt.cu> - 2017-06-08 14:50 +0200
            Re: https_port Darac Marjal <mailinglist@darac.org.uk> - 2017-06-08 15:30 +0200
              Re: https_port Henrique de Moraes Holschuh <hmh@debian.org> - 2017-06-08 17:00 +0200
                Re: https_port "Adiel Plasencia Herrera" <adielp@estereocentro.icrt.cu> - 2017-06-08 17:20 +0200
                Re: https_port Darac Marjal <mailinglist@darac.org.uk> - 2017-06-08 17:30 +0200
                Re: https_port Greg Wooledge <wooledg@eeg.ccf.org> - 2017-06-08 17:40 +0200
                Re: https_port Darac Marjal <mailinglist@darac.org.uk> - 2017-06-08 17:50 +0200
                Re: https_port "Adiel Plasencia Herrera" <adielp@estereocentro.icrt.cu> - 2017-06-08 18:00 +0200
                Re: https_port Jim Ohlstein <jim@mailman-hosting.com> - 2017-06-08 19:10 +0200
                Re: https_port Charlie Kravetz <cjk@teamcharliesangels.com> - 2017-06-09 16:40 +0200
                Reply-to-all or reply-to-list again (was: https_port) Nicolas George <george@nsup.org> - 2017-06-09 16:50 +0200
                Re: Reply-to-all or reply-to-list again (was: https_port) Fungi4All <fungilife@protonmail.com> - 2017-06-09 17:20 +0200
                Re: Reply-to-all or reply-to-list again The Wanderer <wanderer@fastmail.fm> - 2017-06-09 17:20 +0200
                Re: Reply-to-all or reply-to-list again Nicolas George <george@nsup.org> - 2017-06-09 18:00 +0200
                Re: Reply-to-all or reply-to-list again The Wanderer <wanderer@fastmail.fm> - 2017-06-09 21:20 +0200
                Re: Reply-to-all or reply-to-list again Joel Rees <joel.rees@gmail.com> - 2017-06-10 04:20 +0200
                Re: Reply-to-all or reply-to-list again Fungi4All <fungilife@protonmail.com> - 2017-06-10 16:00 +0200
                Re: Reply-to-all or reply-to-list again Joel Rees <joel.rees@gmail.com> - 2017-06-10 16:30 +0200
                Re: Reply-to-all or reply-to-list again Fungi4All <fungilife@protonmail.com> - 2017-06-10 18:00 +0200
                Re: Reply-to-all or reply-to-list again (was: https_port) Gene Heskett <gheskett@shentel.net> - 2017-06-09 17:30 +0200
          Re: NTP.conf   pool vs server Gene Heskett <gheskett@shentel.net> - 2017-06-08 16:10 +0200
    Re: NTP.conf   pool vs server John Hasler <jhasler@newsguy.com> - 2017-06-07 18:10 +0200
      Re: NTP.conf   pool vs server Brian <ad44@cityscape.co.uk> - 2017-06-07 18:30 +0200
        Re: NTP.conf   pool vs server David Wright <deblis@lionunicorn.co.uk> - 2017-06-11 18:00 +0200
          Re: NTP.conf   pool vs server Brian <ad44@cityscape.co.uk> - 2017-06-11 19:30 +0200
      Re: NTP.conf   pool vs server Teemu Likonen <tlikonen@iki.fi> - 2017-06-08 08:40 +0200
        Re: NTP.conf   pool vs server Curt <curty@free.fr> - 2017-06-08 09:20 +0200
        Re: NTP.conf   pool vs server Gene Heskett <gheskett@shentel.net> - 2017-06-08 15:40 +0200
    Re: NTP.conf   pool vs server Jim Ohlstein <jim@mailman-hosting.com> - 2017-06-07 18:40 +0200
  Re: NTP.conf   pool vs server Kushal Kumaran <kushal@locationd.net> - 2017-06-07 17:00 +0200

csiph-web