|
Last updated August 9, 2001
Network Time Protocol (NTP) is used to
synchronize the clocks of one or more computers to each other as well as to
external non-computer time sources. Synchronized computer clocks make debugging
and auditing much easier in a heterogeneous distributed computing environment.
Please note that "NTP" refers to both a protocol and a particular reference
implementation of that protocol.
This distribution is unsupported freeware that has been ported and packaged
by HP for use on MPE/iX. This software has been minimally tested. HP does not
guarantee updates or problem fixes for this freeware. The complete terms and
conditions regarding this software are listed in the
freeware agreement.
This software comes with MPE installation scripts, MPE installation
instructions, binaries, additional files needed to run the software, and
MPE-specific documentation.
Prerequisites
The following prerequisites apply to this distribution of NTP:
Downloading the software
- Complete the freeware agreement.
- Download the software from the resulting list of links.
- Upload the software to your HP e3000 as a POSIX bytestream file named
/tmp/ntp.tar.Z.
Installing the software
- :HELLO MANAGER.SYS
- :XEQ SH.HPBIN.SYS -L
- cd /tmp
- tar xvfopz /tmp/ntp.tar.Z INSTALL
- Optionally edit the /tmp/INSTALL script to choose a non-random account password, non-system volume set, etc.
- /tmp/INSTALL (i.e. run the INSTALL script)
- The software will be installed into the NTP account.
- You MUST set your PDC hardware clock to the correct UTC time, either by rebooting and running ISL CLKUTIL, or by using the :SETCLOCK command. Afterwards,
verify that the :SHOWCLOCK command reports the correct timezone.
- Modify your system logon UDC to :SETVAR TZ "time-zone-spec". The California time-zone-spec is PST8PDT. Valid time zones are listed in TZTAB.LIB.SYS.
- Add an "ntp 123/udp" entry to SERVICES.NET.SYS and make sure that /etc/services is a symbolic link pointing to /SYS/NET/SERVICES.
Distribution highlights
All files reside in the NTP account in a version-specific group named
Vvvuuffp. A symbolic link named CURRENT points to the active version-specific group.
If you install a newer version of this distribution on top of an existing
installation, a new version-specific group will be created and the CURRENT
symbolic link will be adjusted to point to the new group. The old
version-specific group will NOT be purged by the INSTALL script, so once you
are satisfied the new version is working OK, you will have to manually
:PURGEGROUP the old version if you wish to free up its disk space.
Applications that require a specific version of NTP should reference
files and directories using a pathname prefix of /NTP/Vvvuuffp.
Applications that don't have any version dependencies should use a pathname
prefix of /NTP/CURRENT.
The main files and directories of this distribution are as follows:
- /NTP/CURRENT/JSERVER.sample
- Sample job stream for running a time server on your e3000.
- /NTP/CURRENT/NTPxxxxx
- The NTP program file NMPRGs which must all reside in MPE namespace because
they use PM capability.
- /NTP/CURRENT/bin
- Directory containing the true NTP program file names as symlinks pointing to the NMPRGs in MPE
namespace. When running NTP programs, you should use the names in this
directory:
- ntpd
- Server daemon used to turn your e3000 into an NTP time server.
- ntpdate
- Client used to set your clock from one or more external NTP time servers.
- ntpdc
- Client capable of read/write control over a local or external NTP daemon.
- ntpq
- Client for performing read-only queries from a local or external NTP daemon.
- ntptimeset
- Client similar to ntpdate with an alternative algorithm for setting your clock from three or more external NTP time servers. However, ntpdate is preferred
because it can perform a gradual time adjustment rather than the immediate time jump of ntptimeset.
- ntptrace
- A traceroute for timeserver relationships.
- /NTP/CURRENT/etc
- Directory containing the sample NTP configuration files.
- /NTP/CURRENT/mpebin
- Directory containing various support files for compiling and packaging
this distribution on MPE.
- /NTP/CURRENT/public_html
- Symbolic link pointing to extensive NTP HTML documentation.
- /NTP/CURRENT/src
- Directory containing the NTP source code. All changes required for
MPE have been submitted back to the NTP developers for inclusion into a future
release of NTP. Any MPE changes not yet available from ntp.org are included
in a diff file in this same directory.
- /NTP/PUB
- Directory where you should store any user-modified NTP job streams.
- /NTP/PUB/etc
- Directory where you should store your NTP configuration files. This
directory will also contain POSIX PID files when certain NTP programs are
running.
- /NTP/PUB/public_html
- Directory that enables you to access extensive NTP documentation via
http://your.host.name/~MGR.NTP/.
Compiling the software
This distribution contains pre-compiled binaries that are ready to run, so
compiling is not required. However, if you would like to compile it yourself,
just follow these steps:
- Obtain and install the latest version of the GNU gcc bundle from
http://jazz.external.hp.com/src/gnu/gnuframe.html
- :HELLO MGR.NTP,Vvvuuffp
- :XEQ SH.HPBIN.SYS -L
- cd src/ntp-*
- configure.mpe
- make
- make install
- cd ../..
- relink
How to run the time server
Perform the following steps to turn your e3000 into a time server capable of
providing the current time to other networked machines:
- :HELLO MGR.NTP
- Copy /NTP/CURRENT/etc/server.conf.sample to /NTP/PUB/etc/server.conf. Edit
the new file and decide if you want to enable broadcast NTP.
- Copy /NTP/CURRENT/JSERVER.sample to /NTP/PUB/JSERVER and edit the new file
to make any locally required changes.
- Start the time server via :STREAM JSERVER.PUB.NTP.
- Stop the time server via POSIX kill $(cat /NTP/PUB/etc/server.pid).
The following syslog messages will be generated during normal initialization
of the time server:
ntpd 4.1.0 Tue Aug 7 15:07:09 PDT 2001 (1)
precision = 20 usec
setsockopt SO_REUSEADDR on fails: Operation not supported on socket
setsockopt SO_REUSEADDR on fails: Operation not supported on socket
bind() fd 12, family 2, port 123, addr 127.0.0.1, in_classd=0 flags=0 fails: Address already in use
setsockopt SO_REUSEADDR on fails: Operation not supported on socket
bind() fd 12, family 2, port 123, addr www.xxx.yyy.zzz, in_classd=0 flags=1 fails: Can't assign requested address
create_sockets: setsockopt(SO_REUSEADDR,off) failed: Operation not supported on socket
How to set your e3000 clock from an external NTP server
Perform the following steps to set your e3000 clock with the time obtained
from one or more external NTP servers:
- Select an intranet time server, or visit http://www.ntp.org/
and select one or more public NTP time servers.
- :HELLO MGR.NTP or MANAGER.SYS
- /NTP/CURRENT/bin/ntpdate -B ntpserver1 [ntpserver2 ntpserver3 ...]
Important limitations
There is a bug in the MPE clock adjustment code (SR 5003462838) which prevents
ntpd from accurately making hundreds of tiny adjustments to the e3000 clock. At
best, this prevents ntpd from maintaining clock synch, but at worst, the offset
between the MPE and PDC clocks will slowly increase over time which will result
in a very inaccurate date/time prompt the next time you boot your e3000.
This bug only applies when ntpd is allowed to adjust your local e3000 clock.
It does NOT apply to ntpdate, ntptimeset, or when ntpd is used to make your
e3000 into a time server without adjusting your clock.
For additional information about this bug, please see
http://www.bixby.org/mark/xntpix.html.
For further information
- The official NTP web site of
http://www.ntp.org/.
- Documentation on your own local machine at http://your.host.name/~MGR.NTP/.
- Information about older versions of NTP for MPE/iX can be found at
http://www.bixby.org/mark/xntpix.html.
- The HP3000-L mailing list where you can talk with other users of NTP on
MPE:
|