:: Re: [DNG] ntp setup
Etusivu
Poista viesti
Vastaa
Lähettäjä: Olaf Meeuwissen
Päiväys:  
Vastaanottaja: o1bigtenor
Kopio: Devuan ML
Aihe: Re: [DNG] ntp setup
Hi,

There's been a good deal of good advice already but I just wanted to add
my two yen.

o1bigtenor via Dng writes:

> Greetings
>
> Noticed that my new Beowulf install time was not accurate.
>
> Went looking for a tips page and all I could find was information
> relating to using systemd and or its tools to do such. I know there is
> a way to do this without systemd - - - - - just - - - its been a very
> long time since I've done that.
>
> Please - - - anyone for a short writeup on how to
> install/start/whatever else to ntp without using systemd?


I used to install ntpdate on my laptops and ntp on my servers. Seeing
that ntpdate was deprecated (as per package Description:), I now just
install ntp on my laptops as well.

If your computer's clock is way out of sync, i.e. more than five minutes
if memory serves me right, ntp will refuse to sync the clock on the
assumption that that time difference is on purpose. You can easily, and
at your own peril, adjust the clock using the `date` command with a
reasonably close time. At your own peril because some programs don't
handle large time jumps very well.

Once ntp is syncing the system clock I haven't noticed any issues with
keeping the clock in sync, even on my laptops (booted at least once a
week and with a decent hardware clock).

The one thing that I had to work around was the corporate proxy not
letting traffic through on the NTP port (123) and the corporate DHCP
leases not including any NTP server info. I'm using isc-dhcp-client
and that automatically reconfigures the NTP daemon if there is a change
in NTP server info. That also covers the first time you get a lease.
See /etc/dhcp/dhclient-exit-hooks.d/ntp for the gory details.

In my case there were no *_ntp_servers in the lease info so I cobbled up
a little /etc/dhcp/dhclient-enter-hooks.d/my-domain snippet to set these
variables based on the lease's domain. Works like a charm.

# Mostly. I seems to have issues on the occasional times when I switch
# from wireless to wired on the same domain. Haven't looked into that
# yet ...

Hope this helps,
--
Olaf Meeuwissen, LPIC-2            FSF Associate Member since 2004-01-27
 GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13  F43E B8A4 A88A F84A 2DD9
 Support Free Software                        https://my.fsf.org/donate
 Join the Free Software Foundation              https://my.fsf.org/join