watch
Optional, advanced

Actions:
g set LRP to use local time zone;
g use rdate to set clock (milliseconds accuracy);
g use sntp to set clock (microseconds accuracy).


g LRP on this Site is set to Canada/US pacific time-zone, PST8PDT, -8 GMT winter, -7 GMT summer.
Get a time-zone file for your location from a friend who has a Linux box, in the  /usr/share/zoneinfo folder.
Time-zone files are binary files,  filenames are case sensitive. Here is a sample of zone files.

Copy the appropriate time-zone file to a clean  floppy, then rename that file to myzone.bin    
(filename is case sensitive, use all lower case letters for  myzone.bin ).

Boot up LRP,  login as root, type q to drop to the # prompt, insert the floppy with your time-zone file.

mount  -t   msdos    /dev/fd0   /mnt
cp  /mnt/myzone.bin    /etc/localtime    
(if you see errors, type    ls  /mnt  to view the file names)
chmod  644    /etc/localtime
sync
umount  /mnt
remove the floppy with the time-zone file, re-insert your LRP floppy
lrcfg

choose (b) Backup
choose (2) etc
...you should see some floppy activities... then...
q (quit) twice to go back to the # prompt
date  to show the time before adjustment

rdate  time.nrc.ca  to set the LRP clock against a time server at National Research Council, Ottawa, Canada.
or
rdate  time.nist.gov to set the LRP clock against a time server at NIST Laboratories, Boulder, Colorado, USA

Click here to see a list of stratum-1 time servers around the world.
Some of these time servers accept rdate queries (port 37). Some reject rdate (port 37) queries.


g Use rdate to automatically set the LRP clock (once a day)

lrcfg
2) Systems settings
1) Master LPR settings
lrp_DATE_SERVER="time.nist.gov"  replace time.nist.gov with a friendly and reliable regional time server
ctrl-S and Enter to save
ctrl-C
q
Backup
2) etc

Find a reliable and friendly regional time server in your region that accepts port 37 (time) rdate query,
typically you will find friendly time servers at universities, colleges or research institutions that run Unix servers.

You can also use a g Windows machine and install Tardis, Tardis will respond to rdate queries on
port 37 (have Tardis running "minimized" or as a Windows service in NT/2000/XP ), in other words,
use your Windows machine to synchronize to stratum servers and let it become a friendly local time server.
The only problem is that the Windows machine should be running 24 hours a day. g


g Use SNTP to synchronize LRP clock to stratum-1 or stratum-2 time servers.

(1) Save this file msntp.lrp to your LRP hard disk or floppy disk.
(2) Edit syslinux.cfg, add a word  msntp at the end of the fourth line.
(3) Edit /etc/seawall/apps,  add a line that says    udp   ntp
(4) lrcfg to back up Seawall
(5) reboot
(6) To set time manually:  msntp -r  time.nrc.ca  or  msntp -r time.nist.gov   
(choose a stratum-1 or stratum-2 server, or local time server closest to you, respect their Access Policy)
(many University Computing Departments have un-advertised ntp/sntp time servers, ask them)
(7) Included is msntp manual for your convenience.
(8) Here is a sample of a crontask in /etc/cron.d/ , which invokes msntp once every 3 hours.

Acknowledgement:
msntp is an implementation of the SNTP (RFC2030) protocol, exported by the
High Performance Computing Facility of the University of Cambridge, UK.
It was developed by N.M. Maclaren of the University of Cambridge Computing Service.

The advantage of using msntp (instead of rdate) is that nearly all stratum time servers will respond to sntp queries
(port 123), sntp protocol is more accurate than rdate.
Disadvantage: if the clock drift on your LRP is too large, msntp will refuse to set the clock unless it is
run interactively. Failed msntp sessions will pile up in the process queue and you may need to reboot the LRP. g


Click here to return to the main LRP page

© 2002-2005  Nicholas Fong
Burnaby, B.C., Canada

Revised: July 29, 2005