DB2 10.5 for Linux, UNIX, and Windows

Configuring hosts as Network Time Protocol clients

This topic outlines how to configure a Network Time Protocol (NTP) server to ensure that all servers that the instance runs on have similar time settings.

About this task

By default, the NTP server is setup and configuration is handled by the DB2® installer.

Procedure

To configure hosts as NTP clients:

  1. Specify the NTP server to synchronize to. Open the /etc/ntp.conf file and add the following lines:
    server ntp_server_hostname
    driftfile /etc/ntp.drift 
    tracefile /etc/ntp.trace  
    where ntp_server_hostname represents the hostname or IP address of an NTP server. If you do not have access to an existing NTP server, refer to the "Setting up an NTP Server" topic.
  2. Configure the NTP server to start at system restart:
    • On AIX® operating systems, edit the /etc/rc.tcpip file and uncomment the following line:
      start /usr/sbin/xntpd -x "$src_running"
    • On Linux operating systems, run the chkconfig ntp on command.
  3. Start the NTP server:
    • On AIX operating systems, run the startsrc -s xntpd command.
    • On Linux operating systems, run the server ntp start command.
  4. Verify that the daemon is synchronized. If the daemon is significantly not synchronized with the system clock, it can take over 10 minutes for it to become synchronized. To ensure the daemon is synchronized before continuing you can check the "sys stratum" field:
    • On AIX operating systems, use the output of the lssrc -ls xntpd command.
    • On Linux operating systems, use the output of the ntptrace command.
    The sys stratum field should be less then 16 to continue to the next step.
  5. Finish the synchronization process by running the ntpdate -d ntp_server_hostname command.