Documentation about the ncm-ntpd component

Configure the ntpd daemon to be started, at run time and to use the correct name servers.

Configure state

enable the ntp service to run at 3,4,5 runlevels

[Parameters]

ntp_server0 = ip-time-0.cern.ch

ntp_server1 = ip-time-1.cern.ch

ntp_server2 = ip-time-2.cern.ch

client_networks = undef

Modifying the ntp.conf

change the ntp server domains to ips with the gethostbyname() function ( /etc/ntp.conf understands both fqdn and IPs so we probably wont have any problem writing the fqdns )

  • Remove lines, "restrict default nomodify notrap nopeer noquery","restrict 127.0.0.1","restrict ::1" and add "restrict default ignore", in order to remove restriction
  • Remove all defined servers( e.g. in Centos server 0.centos.pool.ntp.org iburst ) and add our ntp servers e.g for ip-time-0.cern.ch, "server 137.138.18.69", "restrict 137.138.18.69 mask 255.255.255.255 nomodify notrap noquery"
  • Remove fudge servers (e.g server "137.138.16.69 # added by /sbin/dhclient-script") and just add localhost in case of network outages, "fudge 127.127.1.0 stratum 10"
  • allow some debugging via ntpdc, but with no modifications, "restrict 127.0.0.1 nomodify notrap"
  • add our own clients in case we are a real "server", "server 127.0.0.1", "restrict <<IP>> mask <<MASK>> nomodify notrap"
Example of a Centos Box for the /etc/ntp.conf file

$diff /etc/ntp.conf.old /etc/ntp.conf

8d7
< restrict default nomodify notrap nopeer noquery
13,14d11
< restrict 127.0.0.1
< restrict ::1
21,24d17
< server 0.centos.pool.ntp.org iburst
< server 1.centos.pool.ntp.org iburst
< server 2.centos.pool.ntp.org iburst
< server 3.centos.pool.ntp.org iburst
59,60c52,61
< server 137.138.16.69 # added by /sbin/dhclient-script
< server 137.138.17.69 # added by /sbin/dhclient-script
---
> # This file is under NCM-ntpd control.
> restrict default ignore
> server 137.138.18.69
> restrict 137.138.18.69 mask 255.255.255.255 nomodify notrap noquery
> server 137.138.16.69
> restrict 137.138.16.69 mask 255.255.255.255 nomodify notrap noquery
> server 137.138.17.69
> restrict 137.138.17.69 mask 255.255.255.255 nomodify notrap noquery
> fudge 127.127.1.0 stratum 10
> restrict 127.0.0.1 nomodify notrap


Modifying the /etc/ntp/step-tickers

Rewrite everything with the ntp servers IPs

e.g

$ cat /etc/ntp/step-tickers
137.138.18.69
137.138.16.69
137.138.17.69


Reload the ntp service if the files are changed.

Unconfigure State

Nothing done to unconfigure the ntp component.

Edit | Attach | Watch | Print version | History: r6 < r5 < r4 < r3 < r2 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r6 - 2015-10-27 - AristeidisBoutselis
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Sandbox All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback