Installing and Administering Internet Services
Chapter 7 309
Configuring the Network Time Protocol (NTP)
Advanced NTP Topics
The first entry causes packets from source addresses on net 193.100 to be
ignored. However, packets from host 193.100.10.8 are unrestricted, as
specified by the second entry. The two restriction list entries effectively
cause all packets from net 193.100 to be ignored, with the exception of
packets from host 193.100.10.8.
The following are examples of restriction list entries for a local host with
the address 193.100.100.7. These entries assume that ntpq requests to
the local host can be made only from the local host or the host with
address 193.8.10.1, while the local host only synchronizes to a time
source on net 193.100.
#default entry - matches *all* source addresses
restrict default notrust nomodify
#trust for time, but do not allow ntpq requests
restrict 193.100.0.0 mask 255.255.0.0 nomodify noquery
#ignore time requests, but allow ntpq requests
restrict 193.8.10.1 noserve
#local host address is unrestricted
restrict 193.100.100.7
Starting and Stopping xntpd
To start xntpd, do one of the following:
• Set the environment variable XNTPD to 1 in the file
/etc/rc.config.d/netdaemons. This causes xntpd to start
automatically whenever the system is booted.
• Issue the following command to run the xntpd startup script:
/sbin/init.d/xntpd start
Command line arguments for starting xntpd may be specified with the
XNTPD_ARGS environment variable in the file
/etc/rc.config.d/netdaemons. See the xntpd man page for more
information about command line arguments.
NOTE xntpd should be operated on a continuous basis. If it is necessary to stop
xntpd, the interval when it is not running should be kept to a minimum.