Overview

 

Good system time of day quality is needed on LOIS computers in order to

  • Communicate effectively with the UI (Loui)- this will fail if the time difference between LOIS & LOUI computers is more than about 5 seconds.
  • Have good time for the FITS headers- especially important for occultations and transits- time offset from reality on the LOIS computers should be much less than 1 sec.


This note describes how to evaluate and set up time services for the LOIS computers, especially the Centos 6.2 Linux hosts at DCT. These hosts are normally operated in headless mode, so command lines as  described below are used. The UI (Loui) computers use Apple configuration (System Preferences) for the ntp setup, which are reasonably well known and not described further here. The level of timing accuracy required for these is much less in any case, since there is no relation to scientific data timing.

To maintain quality of service for time, (QoS), ntpd is used. The computers themselves have poor clock/calendar h/w- at the level of a very cheap watch- so you would need to check and reset time several times in the night if relying on a manual operation. Ntpd should start automatically when the computer is restarted, and remain up. The timecheck and st scripts will inform you if ntpd is not running. The timefix script, run as super user, will allow you to stop, start, or restart ntpd if you need to do that. There is also an operation called ntpdate which will access a remote timeserver and do a good time correction on a one time basis; this can be invoked with timefix also.

 

If ntpd is running, a system utility called ntpq is available to give you a table of the ntp protocol status with all of the remote ntp servers that are in the mix. The interesting numbers in this table are reach (1 at startup, up to 377 for complete synchronization) and offset (in msec, gives time displacement with the given server from this host). The timecheck script will summarize this information in a single line.

The selection of server hosts to use with ntp is set up in /etc/ntp.conf, which is maintained by the administrator. Currently it includes several GPS units with ntp server capability, one at DCT and one at Anderson Mesa.

The st script is available on all lois computers, as are ntpd, ntpdate and ntpq. Timecheck and timefix are currently on deveny only.

 

NTPD & NTPDATE

 

Ntpd is invoked with a simple 

/usr/sbin/ntpd

and is immediately placed in the background. This can only be done as superuser. Ntpd will attempt to contact servers in the ntp.conf list and establish time synchronization with them. The progress of this synchronization is described by a parameter called  reach, which begins at  1 with first contact- complete synchronization is associated with the value 377. The synchronization process usually requires no more than about 15 minutes to complete. It accelerates this process in some cases to use ntpdate initially to get the time on the host close to reality. Otherwise, since the process of moderating the system clock is done slowly, the difference in time between the host and  the several time servers, a variable called the offset, can take a surprisingly long  time to become reasonable.

  • No labels