This page discusses compatibility features Domain Time provides for administrators accustomed to using command-line utilities included with ntpd,
one of the more popular NTP time synchronization programs often used on Linux and other platforms.
IMPORTANT: Note that NTP (the protocol) is not the same as ntpd (the program).
Like Domain Time, the ntpd daemon synchronizes time using the NTP protocol, however ntpd and Domain Time are different programs, with
different approaches to peering, clock steering and other operations. The ntpd package comes with a number of utilities such as ntpq that provide
statistical or other control or output. These utilties are not part of NTP (the protocol), but specific to ntpd (the program).
Domain Time is not a port of ntpd. Because Domain Time does not share a code base with ntpd, it is not vulnerable to
amplification attacks or the recently discovered ntpd security vulnerabilities. These security problems are not part of the NTP
protocol itself; they are peculiar to ntpd's implementation.
Although both programs use similar statistical methods to eliminate outliers and calculate the intersection of sample sets,
Domain Time does not use the canonical ntpd algorithms or keep individual peer statistics in the same way ntpd does. Domain
Time uses more sophisticated methods of clock steering, especially on those versions of Windows that have
inherent clock control issues (i.e. Server 2008/Win7/Vista). Domain Time also is able to compare samples obtained
using multiple protocols to improve sample accuracy and offset calculations, as well as provide time to a wider range of clients.
ntpq-compatible responses can be disabled if desired by setting the following registry value to True:
HKEY_LOCAL_MACHINE\SOFTWARE\Greyware\Domain Time Server[Client]\Parameters\NTP Query Disabled
Turning off ntpq responses does not disable the ability to obtain the time using NTP (the protocol).
Domain Time Server answers ntpdate queries to allow for immediate localclock synchronization.
Domain Time Client does not.
Domain Time has historically supported a subset of queries from ntpq. Until recently, however, the output could be confusing for
administrators who believed Domain Time was ntpd under the hood. In particular, Domain Time has never supported the concept
of a single sys.peer; all providers currently configured and available are used to create the set of samples, and the
"true time" is derived from statistical analysis of all the samples. This means that no one server necessarily is marked as
sys.peer; it also means that more than one could be marked this way.
As of version 5.2.b.20170101, Domain Time reorders its output for ntpq to conform more closely to what and an ntpd
administrator would expect to see. If more than one source is used to steer the clock, only the first is marked sys.peer;
the remainder are marked as candidates. If a source is consulted but not used, it will be marked sel_reject,
sel_outlier, or sel_falsetick, depending on which statistical anomaly eliminated the sample
(see the section Peer Status Word below).
In this report, three servers were used to steer the clock (marked with an asterisk or a plus sign in the first column).
Two servers were rejected as outliers (a minus sign in the first column), and the remainder failed the statistical tests
for other reasons. A more complete accounting of the standard deviation, standard error, and rejection reasons is
available from Domain Time's text log. Domain Time does not track jitter in the same fashion as ntpd does, so the jitter
column will always be 0.000.
This report shows more detail, including that the first server used symmetric authentication. The output of both commands
differs from ntpd's in one significant area: The "reach" column shown for peers, and the "cnt" column shown for associations,
refer to how many samples were taken from that particular server during the most recent time check event. Domain Time does not use
ntpd's concept of an 8-bit shift register to record reachability. A server that does not respond is not included in the output
at all, so it is not possible to shift a 0 into the rightmost bit of the count register. The "cnt" column displayed by a Domain Time
machine will be between 1 and 15 (0x01-0x0F, or O001-O017), because the Peer Status Word allots only 4 bits for the count.
The "reach" column will be between 1 and 255 (0x01-0xFF, O377) because the reach is calculated based on the number of
samples as if it were a proper shift-register. Since unreachables are never present, the only possible decimal values for
the "reach" column are 1, 3, 7, 15, 31, 63, 127, and 255. For machines using PTP as the time source, the reach will almost
always be 255 (0xFF, O377).
NTP Loopstats and Peerstats
As of version 5.2.b.20170101, Domain Time has added the ability to keep loopstats and peerstats files in ntpd's version 4 file format,
including symlinks to the current file.
The default folder is C:\Program Files\Domain Time II\NTP Stats\, but
you may change this by editing this registry value:
HKEY_LOCAL_MACHINE\SOFTWARE\Greyware\Domain Time Server[Client]\Parameters\NTP Stats Folder
Changes to the log location take effect the next time a stat is generated. Symlinks will not be maintained if you use a UNC folder path,
or if the operating system is XP/2003.
You may enable or disable peerstats and loopstats from the Domain Time Control Panel applet's Logs and Status
page. The loopstats file and the peerstats file follow the log roll settings for Text Log Archiving on that page. The filename format
is just "loopstats" and "peerstats" if log roll is set to never; "loopstats.yyyymmdd" and "peerstats.yyyymmdd" if set to daily;
"loopstats.yyyyWn" and "peerstats.yyyyWn" if set to weekly; and "loopstats.yyyymm" and "peerstats.yyyymm" if set to monthly.
When the log roll is set to never, no symlink is generated, because the bald filename is already the name the symlink would have.
For other log rolling, symlinks for "loopstats" and "peerstats" are generated to point to the current daily, weekly, or monthly file.
They are text files, each line terminated by a single LF, each field separated by a single space. Values that are inapplicable or inexpressible in ntpd's format are set to 0.0 and will never vary.
Domain Time keeps offsets and delay measurements in hectonanoseconds (tenths of a microsecond). There will always be exactly seven significant digits after the decimal point.
Note: The protocol used to obtain the time samples is irrelevant to loopstats and peerstats generation. If enabled, even Domain Time machines not using NTP at all will have compatible loopstats and peerstats files.
The fields for loopstats, from left to right, are Modified Julian Day, Seconds.fractions past midnight UTC, time offset in seconds, frequency offset in PPM, RMS jitter in seconds, Allan deviation in PPM, and the exponent to which 2 should be raised to calculate the number of seconds between time checks.
Domain Time does not track frequency offset, RMS jitter, or Allan deviation in a way that can be expressed in the loopstats file,
so these three fields will always be 0.0. Domain Time tracks syntonicity, but this is not directly translatable into jitter
and deviation, especially if multiple protocols are used, or if one of them is PTP.
Additionally, Domain Time can be set to obtain the time at any interval, so the 6 in the final field (representing 26, or 64 seconds)
is not necessarily accurate. In the case above, Domain Time was set to check every 60 seconds, which is not directly representable
as a power of two. Domain Time rounds the output to the nearest power of two.
A loop, for Domain Time's purposes, corresponds to a time check event. One line will be written each time Domain Time checks with
its sources, or, in the case of PTP, summarizes the activity over the past n seconds. The schedule may be set to variable or fixed, and an unscheduled check may occur when a sync is signaled, either
internally or externally.
The fields for peerstats are, from left to right, Modified Julian Day, Seconds.fractions past midnight UTC, the textual IP
address (dotted quad for IPv4; standard notation for IPv6) of the server, a four-digit hex number (without the leading 0x)
representing the Peer Status Word, followed by offset, delay, dispersion and RMS jitter, all in seconds.
Domain Time does not calculate dispersion and RMS jitter in a format that can be represented in the peerstats file, so these two
fields will always be 0.0.
A peer, for Domain Time's purposes, is a configured or discovered server, regardless of protocol used, that provides time samples.
A peer that fails to provide a sample at a given loop will not have a line.
Since Domain Time only includes peers that have provided time samples, the reach bit will usually be set. The only exception is if
Domain Time is using broadcast/multicast time sources (not including PTP), in which case the bcst bit will be set instead of reach.
Again, since Domain Time only includes peers that have provided time samples, either both auth and authenb bits
will be set, or both will be cleared. A server configured to use authentication that fails because of an authentication failure does
not provide a time sample, and will not appear in the list.
The config bit represents whether the time source was configured (i.e., in a list of servers Domain Time was told to use), or was
discovered by Domain Time in auto-configure mode. For PTP time sources, it is considered configured if the list of PTP masters is
restricted by IP or CIDR mask. If Domain Time follows the BMC without restriction, the source is considered discovered rather than
The only applicable codes, appearing in the last four bits, are reachable (the default), sys_peer, and popcorn.