Clock synchronization

You can configure your NetScaler appliance to synchronize its local clock with a Network Time Protocol (NTP) server. This ensures that its clock has the same date and time settings as the other servers on your network.

You can configure clock synchronization on your appliance by adding NTP server entries to the ntp.conf file from either the GUI or the command line interface, or by manually modifying the ntp.conf file and then starting the NTP daemon (NTPD). The clock synchronization configuration does not change if the appliance is restarted, upgraded, or downgraded. However, the configuration does not get propagated to the secondary NetScaler in a high availability setup.

Note: If you do not have a local NTP server, you can find a list of public, open access, NTP servers at the official NTP site,

http://www.ntp.org, under Public Time Servers List. Before configuring your NetScaler to use a public NTP server, be sure to read the Rules of Engagement page (link included on all Public Time Servers pages).

In NetScaler release 11, the NTP version has been updated from 4.2.6p3 to 4.2.8p2.

Set clock synchronization

To configure clock synchronization, you must add NTP servers and then enable NTP synchronization.

To add an NTP server by using the command line interface

At the command prompt, type the following commands to add an NTP server and verify the configuration:

  • add ntp server (<serverIP> | <serverName>) [-minpoll <positive_integer>] [-maxpoll <positive_integer>]
  • show ntp server

Example

> add ntp server 10.102.29.30 -minpoll 6 -maxpoll 11

To configure an NTP server by using the GUI

Navigate to SystemNTP Servers, and create the NTP server.

Start NTP daemon

When you enable NTP synchronization, the NetScaler starts the NTP daemon and uses the NTP server entries in the ntp.conf file to synchronize its local time setting. If you do not want to synchronize the appliance time with the other servers in the network, you can disable NTP synchronization, which stops the NTP daemon (NTPD).

To enable NTP synchronization by using the command line interface

At the command prompt, type one of the following commands:

enable ntp sync

To enable NTP synchronization by using the GUI

Navigate to SystemNTP Servers, click Action and select NTP Synchronization.

Configure clock synchronization

You can configure clock synchronization manually by logging on to the NetScaler appliance and editing the ntp.conf file.

To enable clock synchronization on your NetScaler appliance by modifying the ntp.conf file

  1. Log on to the command line interface.
  2. Switch to the shell prompt.
  3. Copy the /etc/ntp.conf file to /nsconfig/ntp.conf, unless the /nsconfig directory already contains an ntp.conf file.
  4. For each NTP server you want to add, you must add the following two lines to the /nsconfig/ntp.conf file:

server <IP address for NTP server> iburst

restrict <IP address for NTP server> mask <netmask> nomodify notrap nopeer noquery

Note: For security reasons, there should be a corresponding restrict entry for each server entry.

Example:

In the following example, an administrator has inserted # characters to “comment out” an existing NTP entry, and then added a new entry:

#server 1.2.3.4 iburst

#restrict 1.2.3.4 mask 55.255.255.255 nomodify notrap nopeer noquery

server 10.102.29.160 iburst

restrict 10.102.29.160 mask 255.255.255.255 nomodify notrap nopeer noquery

   5. If the /nsconfig directory does not contain a file named rc.netscaler, create the file.

   1. Add the following entry to /nsconfig/rc.netscaler: /bin/sh /etc/ntpd_ctl full_start

This entry starts the ntpd service, checks the ntp.conf file, and logs messages in the /var/log directory.

This process runs every time the NetScaler is restarted.

   7. Restart the NetScaler appliance to enable clock synchronization. Or, to start the time synchronization    process without restarting the appliance, enter the following commands at the shell prompt:

  • rm /etc/ntp.conf
  • ln -s /nsconfig/ntp.conf /etc/ntp.conf
  • /bin/sh /etc/ntpd_ctl full_start

Clock synchronization