[ntpsec commit] tickadj -> ntptickadj. It' s portable now and can be a full-fledged component.
Eric S. Raymond
esr at ntpsec.org
Thu Oct 8 18:12:42 UTC 2015
Module: ntpsec
Branch: master
Commit: fd6b1c1bbb11755d64f5e65f6165c1cd0b6dc492
Changeset: http://git.ntpsec.org/ntpsec/commit/?id=fd6b1c1bbb11755d64f5e65f6165c1cd0b6dc492
Author: Eric S. Raymond <esr at thyrsus.com>
Date: Thu Oct 8 14:11:26 2015 -0400
tickadj -> ntptickadj. It's portable now and can be a full-fledged component.
---
devel-docs/TODO | 2 +-
docs/asciidoc.conf | 2 ++
docs/debug.txt | 2 +-
docs/includes/manual.txt | 2 +-
docs/index.txt | 3 +++
docs/{tickadj.txt => ntptickadj.txt} | 29 ++++++++++++++---------------
scripts/calc_tickadj/calc_tickadj | 2 +-
sntp/loc/debian | 2 +-
sntp/loc/legacy | 2 +-
sntp/loc/redhat | 2 +-
sntp/loc/solaris | 2 +-
util/README | 2 +-
util/{tickadj.c => ntptickadj.c} | 2 +-
util/wscript | 2 +-
14 files changed, 30 insertions(+), 26 deletions(-)
diff --git a/devel-docs/TODO b/devel-docs/TODO
index 51909f1..9049e48 100644
--- a/devel-docs/TODO
+++ b/devel-docs/TODO
@@ -102,7 +102,7 @@ is not yet tested anywhere but in ntpd itself.
| Inside docs | Outside docs
| docs/ntp_conf.txt | ntpd/ntp.conf.txt
| docs/ntpdsim.txt | docs/ntpdsim_new.txt
-| docs/tickadj.txt | -
+| docs/ntptickadj0.txt| -
| - | ntpd/ntp.keys.txt
| - | scripts/calc_tickadj/calc_tickadj.txt
| - | scripts/summary.txt
diff --git a/docs/asciidoc.conf b/docs/asciidoc.conf
index d586c87..a154dfd 100644
--- a/docs/asciidoc.conf
+++ b/docs/asciidoc.conf
@@ -21,6 +21,7 @@ ntpdconf=ntpd.conf
ntpkeygen=ntp-keygen
ntpkeys=ntp.keys
ntpq=ntpq
+ntptickadj=tntptickadj
ntptime=ntptime
ntpwait=ntp-wait
sntp=sntp
@@ -29,6 +30,7 @@ ntpconfman=ntp.conf(5)
ntpkeygenman=ntp-keygen(8)
ntpkeysman=ntp.keys(5)
ntpqman=ntpq(1)
+ntptickadjman=tntptickadj(8)
ntptimeman=ntptime(1)
ntpwaitman=ntp-wait(1)
sntpman=sntp(1)
diff --git a/docs/debug.txt b/docs/debug.txt
index 3a7f193..1929bfc 100644
--- a/docs/debug.txt
+++ b/docs/debug.txt
@@ -144,7 +144,7 @@ Record the time of day and offset displayed by the `{ntpq}`
link:ntpq.html#pe[`pe`] command. Wait for an hour or so and record the
time of day and offset. Calculate the frequency as the offset difference
divided by the time difference. If the frequency is much above 100 PPM,
-the link:tickadj.html[tickadj] program might be useful to adjust the
+the link:ntptickadj.html[{ntptickadj}] program might be useful to adjust the
kernel clock frequency below that value. For systems that do not support
this program, this might be one using a command in the system startup
file.
diff --git a/docs/includes/manual.txt b/docs/includes/manual.txt
index 31d5310..ab1e008 100644
--- a/docs/includes/manual.txt
+++ b/docs/includes/manual.txt
@@ -3,7 +3,7 @@
* link:ntpq.html[`{ntpq}` - standard NTP query program]
* link:sntp.html[`{sntp}` - Simple Network Time Protocol (SNTP) client]
* link:ntptrace.html[`ntptrace` - trace a chain of NTP servers back to the primary source]
-* link:tickadj.html[`tickadj` - set time-related kernel variables]
+* link:ntptickadj.html[`{ntptickadj}` - set time-related kernel variables]
* link:ntptime.html[`{ntptime}` - read and set kernel time variables]
* link:keygen.html[`{ntpkeygen}` - generate public and private keys]
* link:ntpdsim_new.html[`ntpdsim` - Network Time Protocol (NTP) simulator]
diff --git a/docs/index.txt b/docs/index.txt
index 8a292f9..965cd30 100644
--- a/docs/index.txt
+++ b/docs/index.txt
@@ -82,6 +82,9 @@ few will be user-visible:
* The deprecated ntpdc utility, long since replaced by {ntpq}, has been removed.
+* The `tickadj` utility has been rebamed `ntptickadj` and is now fully
+ portable.
+
* A number of obsolete refclocks have been removed.
* The deprecated ntpdate program has been replaced with a shell
diff --git a/docs/tickadj.txt b/docs/ntptickadj.txt
similarity index 83%
rename from docs/tickadj.txt
rename to docs/ntptickadj.txt
index 9779f50..234f9a8 100644
--- a/docs/tickadj.txt
+++ b/docs/ntptickadj.txt
@@ -1,31 +1,31 @@
-= `tickadj` - set time-related kernel variables =
+= `ntptickadj` - set time-related kernel variables =
== Synopsis ==
-`tickadj [ -Aqs ] [ -a tickadj ] [ -t tick ]`
+`{ntptickadj} [ -Aqs ] [ -a tickadj ] [ -t tick ]`
== Description ==
-The `tickadj` program reads, and optionally modifies, several
-timekeeping-related variables. It relies on the adjtimex(2) or
-ntp_adjtime(2) system calls.
+The `{ntptickadj}` program (formerly named just `tickadj`) reads, and
+optionally modifies, several timekeeping-related variables. It relies
+on the adjtimex(2) or ntp_adjtime(2) system calls.
These tweaks are almost never necessary on hardware new enough to have
a fully POSIX.1-2001-conformant Unix. This utility is deprecated and
exists mainly for backward compatibility to old scripts. In the future
it may be removed or merged into a more general tuning tool.
-The particular variables that can be changed with `tickadj` include
+The particular variables that can be changed with `{ntptickadj}` include
`tick`, which is the number of microseconds added to the system time
for a clock interrupt, and possibly `tickadj`, which sets the slew
rate and resolution used by the `adjtime` system call. These should
be members of the `struct timex` that adjtimex(2) operates on.
-By default, with no arguments, `tickadj` reads the `struct timex`
+By default, with no arguments, `{ntptickadj}` reads the `struct timex`
variable(s) of interest and displays them. At the same time, it
determines an "optimal" value for the value of the `tickadj` variable
if the intent is to run the Network Time Protocol (NTP) daemon,
-and prints this as well. Since the operation of `tickadj` when reading
+and prints this as well. Since the operation of `{ntptickadj}` when reading
the kernel mimics the operation of similar parts of the `{ntpd}` program
fairly closely, this can be useful when debugging problems with
`{ntpd}`.
@@ -57,14 +57,14 @@ microseconds per tick until the specified adjustment has been completed.
Unfortunately, in most Unix implementations the tick increment must be
either zero or plus/minus exactly `tickadj` microseconds, meaning that
adjustments are truncated to be an integral multiple of `tickadj` (this
-latter behaviour is a misfeature, and is the only reason the `tickadj`
+latter behaviour is a misfeature, and is the only reason the `{ntptickadj}`
code needs to concern itself with the internal implementation of
`tickadj` at all). In addition, the stock Unix implementation considers
it an error to request another adjustment before a prior one has
completed.
Thus, to make very sure it avoids problems related to the roundoff, the
-`tickadj` program can be used to adjust the values of `tick` and
+`{ntptickadj}` program can be used to adjust the values of `tick` and
`tickadj`. This ensures that all adjustments given to `adjtime()` are an
even multiple of `tickadj` microseconds and computes the largest
adjustment that can be completed in the adjustment interval (using both
@@ -84,10 +84,9 @@ if `tickadj` is too small, NTP will have difficulty if it needs to make
an occasional large adjustment. While the daemon itself will read the
kernel's values of these variables, it will not change the values, even
if they are unsuitable. You must do this yourself before the daemon is
-started using the `tickadj` program included in the `./util` directory
-of the distribution. Note that the latter program will also compute an
-optimal value of `tickadj` for NTP use based on the kernel's value of
-`tick`.
+started using the `{ntptickadj}` program. Note that the latter program
+will also compute an optimal value of `tickadj` for NTP use based on
+the kernel's value of `tick`.
In order to maintain reasonable correctness bounds, as well as
reasonably good accuracy with acceptable polling intervals, `{ntpd}` will
@@ -105,7 +104,7 @@ of `tick` will change the frequency by about 100 PPM.
`-t` 'tick'::
Set the kernel variable `tick` to the value _`tick`_ specified.
`-q`::
- Normally, `tickadj` is quite verbose about what it is doing. The `-q`
+ Normally, `{ntptickadj}` is quite verbose about what it is doing. The `-q`
flag tells it to shut up about everything except errors.
'''''
diff --git a/scripts/calc_tickadj/calc_tickadj b/scripts/calc_tickadj/calc_tickadj
index 7272b82..81a39cd 100755
--- a/scripts/calc_tickadj/calc_tickadj
+++ b/scripts/calc_tickadj/calc_tickadj
@@ -17,7 +17,7 @@ sub run {
my $tick = $opts->{'tick'};
if (!$tick) {
- my ($fl) = `tickadj`;
+ my ($fl) = `ntptickadj`;
if (defined $fl && $fl =~ /(?:KERNEL|PRESET)?\s*tick\s+=\s+(\d+)/) {
$tick = $1;
}
diff --git a/sntp/loc/debian b/sntp/loc/debian
index 8470bba..4090a9c 100644
--- a/sntp/loc/debian
+++ b/sntp/loc/debian
@@ -12,6 +12,6 @@ ntpsweep,bin,1
ntptime,sbin,8
ntptrace,bin,1
sntp,bin,1
-tickadj,sbin,8
+ntptickadj,sbin,8
timetrim,sbin,8
update-leap,sbin,8
diff --git a/sntp/loc/legacy b/sntp/loc/legacy
index c8422d1..185d73a 100644
--- a/sntp/loc/legacy
+++ b/sntp/loc/legacy
@@ -12,6 +12,6 @@ ntpsweep,noinst,1
ntptime,bin,1
ntptrace,bin,1
sntp,bin,1
-tickadj,bin,1
+ntptickadj,bin,1
timetrim,bin,1
update-leap,bin,1
diff --git a/sntp/loc/redhat b/sntp/loc/redhat
index d455613..4ce2c5f 100644
--- a/sntp/loc/redhat
+++ b/sntp/loc/redhat
@@ -12,5 +12,5 @@ ntpsweep,noinst,8
ntptime,sbin,8
ntptrace,sbin,8
sntp,sbin,8
-tickadj,sbin,8
+ntptickadj,sbin,8
timetrim,sbin,8
diff --git a/sntp/loc/solaris b/sntp/loc/solaris
index 6b69cfe..9980941 100644
--- a/sntp/loc/solaris
+++ b/sntp/loc/solaris
@@ -12,5 +12,5 @@ ntpsweep,noinst,1m
ntptime,sbin,1m
ntptrace,sbin,1m
sntp,sbin,1m
-tickadj,sbin,1m
+ntptickadj,sbin,1m
update-leap,sbin,1m
diff --git a/util/README b/util/README
index e130180..b34fb3e 100644
--- a/util/README
+++ b/util/README
@@ -65,7 +65,7 @@ testrs6000.c::
If you set it less than 40 us do so at your own risk!" The RS6000
is dead, but this is kept around as a way to bogon-test other kernels.
-tickadj.c::
+ntptickadj.c::
Can be used to read and set various kernel parameters affecting NTP
operations. See the tickadj page in the HTML documentation for further
details.
diff --git a/util/tickadj.c b/util/ntptickadj.c
similarity index 96%
rename from util/tickadj.c
rename to util/ntptickadj.c
index 95327d8..53e098b 100644
--- a/util/tickadj.c
+++ b/util/ntptickadj.c
@@ -1,5 +1,5 @@
/*
- * tickadj - read, and possibly modify, the kernel `tick' and
+ * ntptickadj - read, and possibly modify, the kernel `tick' and
* `tickadj' variables', using adjtimex(2) or
* ntp_adjtime(2). This is included only for compatibility
* with old scripts. and its former support for unsafe
diff --git a/util/wscript b/util/wscript
index 25dfdf5..b3d554c 100644
--- a/util/wscript
+++ b/util/wscript
@@ -4,7 +4,7 @@ def build(ctx):
srcnode = ctx.srcnode.abspath()
bldnode = ctx.bldnode.abspath()
- util = ['hist', 'jitter', 'precision', 'propdelay', 'ntptime', 'sht', 'testrs6000', 'tg2', 'tickadj']
+ util = ['hist', 'jitter', 'ntptickadj', 'precision', 'propdelay', 'ntptime', 'sht', 'testrs6000', 'tg2']
if ctx.get_define("HAVE_SYS_TIMEPPS_H"):
util += ["pps-api"]
More information about the vc
mailing list