From: glenn@herald.usask.ca (Glenn Hollinger)
Subject: NTP and DTSS at the University of Saskatchewan
Originator: glenn@herald.usask.ca
Organization: University of Saskatchewan
Date: Wed, 9 Sep 1992 17:40:49 GMT

We are now using DEC DTSS and NTP to synchronize our campus computers.
This seems to be a recurring topic of questions, so I put together some
information on what we have done here.  First, an ascii diagram of the
layout of things here and then a rather lengthy history of how things
progressed.  As with all things, discussion is encouraged.  I will
answer questions if I can and post a summary to the net.

Glenn Hollinger                  glenn@herald.usask.ca
University of Saskatchewan       +1-306-966-4827


   Physical layout:
                                    _______Ethernet_____________________
                                       |                 |         |
        GOES                       MicroVAX 2000 &      UNIX      VMS
      satellite ---RS232---------> VAXstation 2000    Systems   Systems
        clock

   Time synchronization flow:

       GOES       Ascii     Xntp3                     synchronized
     satellite ---Time----> daemon ---adjtime calls----> local
       clock      Codes    (Ultrix)                      clock
                           /      \
                          /        \
                         V          V
                       V3         V1, V2, V3 NTP
                  Broadcast NTP    Peer-to-Peer
                      /              |       \
                     /               |        \
                    V                V         V
                 V3 NTP           NTP peers    DTSS NTP
           broadcast clients      (Unix)     Time Providers--->DTSS Server
                (Unix)                           (VMS)            (VMS)
                                                                    |
                                                                    |
                                                                    V
                                                               DTSS Clients
                                                                  (VMS)


                     Traveling Time Using Xntp and DECdts
                                      or
                How to sink 150 computers without really trying

This text is a chronological history of time synchronization at the University
of Saskatchewan.  Like most campuses, we have many independent computer
systems.  Each of these systems had their time set at install time using the
installer's wrist watch as the accurate time source.  After that, they ran
independently and incensed.

Some operating systems do use various methods to synchronize, such as the rdate
techniques of Ultrix and SunOS (which are different from each other). This
helped those computers somewhat, but didn't solve the problem completely, even
for them.

About September of 1990 the brand new CA*net network was installed with its
high-speed 56 kbit backbone spanning the country and linking our campus to the
internet.  At this time, we saw the opportunity to use the NTP servers on the
internet.  By December of 1990, we started using NTP to synchronize some of our
Unix computers.  Not all OSes could be handled, but this was a start.

Using NTP version 1, we synced up most of the campus Ultrix and SunOS boxes
(and other unixes).  This worked fairly well getting time from Stratum 1 NTP
servers in the states. But, CA*net was such a success that it started getting
busier, especially at the CA*net-Internet links.  Even with line speed
increases in critical areas, by December 1991 decent synchronization to US
servers was becoming harder to get.

We needed a plan.  The plan we came up with was to make a decent local clock we
could rely on.  In February 1992, we scrounged a MicroVAX 2000 running Ultrix.
This node with Xntp software made a decent stratum 2 NTP server, but didn't
solve our troubles communicating to US stratum 1 servers.  We started casting
about looking for accurate time sources.

The first thing we latched on to was CHU.  This turned out to be a dead end
because of difficulties establishing reliable radio reception.

Next, we looked into a satellite clock our Geologists were using, a Kinimetrics
Truetime 468-DC.  This is a nice time source, but not supported by any NTP
software at that time.

From February through May 1992 we took xntp3 beta and developed a GOES clock
module to support the GOES satellite clock.  Several iterations were done with
long-term testing for problems throughout.  The final result is a Stratum 1 NTP
server on our local ethernet.

Using broadcast NTP as well as NTP versions 1 2 and 3, it was relatively
straight forward to distribute this time to Unix systems throughout the campus.
However, this did not solve the problem for our 75 or so VMS systems.

We heard that DECdts might solve this problem.  After looking into it, we found
out that Decnet 5.0 for Ultrix includes the DTSS server and could pick up time
from an NTP server or a local ntp-synced clock.  Later, we found out the DECdts
in the VMS Decnet extensions can also talk to remote NTP servers if a public
domain extension was used.

After 2 months work, we discovered that the only way to use NTP and dtss on the
same node is to prevent NTP from adjusting the system clock and let dtss do it.
We felt this was an unreasonable limitation.  So we junked OSI and, using
public domain extensions to the VMS DTSS time provider, set up our DTSS servers
on VMS to pick time up via UCX from the NTP servers.  These DTSS servers then
synchronize the VMS DTSS clients on the network.

As MicroVax and VAXstation 2000s are becoming less useful, we have picked up a
second system to be a redundant NTP server and a third system for spare parts.
With a combination of scrounged hardware, some software development and some
vendor supplied software, we will soon have our campus systems synchronized
within about one hundredth of a second.

Future directions; The GOES clock is not the best timekeeping device.  We will
be constructing the gadget box as described in the xntp3 distribution to
connect its 1PPS output.  This will hopeful improve accuracy quite a bit.
Also, the GOES clock is not ours.  We are looking at the new Motorola GPS
receiver as a replacement which can provide a 1PPS signal with 50 nanoseconds
accuracy for a reasonable cost. 

                                          Glenn Hollinger,
                                          Systems Group,
                                          Computing Services,
                                          University of Saskatchewan.