From c58d66510a4e1298bfaef613fd625b3a446ae832 Mon Sep 17 00:00:00 2001 From: jmc <> Date: Wed, 11 Mar 2015 19:38:48 +0000 Subject: [PATCH] -s is not optional, sadly; while here i've reformatted the page to stop kidding that -s is 4 options; original issue kind of spotted by adam thompson, though note i am not fixing the issue he complained about (i'll address that mail in a minute); --- src/usr.sbin/ntpd/ntpctl.8 | 31 +++++++++++++++++++------------ src/usr.sbin/ntpd/ntpd.c | 4 ++-- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/src/usr.sbin/ntpd/ntpctl.8 b/src/usr.sbin/ntpd/ntpctl.8 index b09c3310..ed527ba0 100644 --- a/src/usr.sbin/ntpd/ntpctl.8 +++ b/src/usr.sbin/ntpd/ntpctl.8 @@ -1,4 +1,4 @@ -.\" $OpenBSD: ntpctl.8,v 1.7 2015/02/10 06:40:08 reyk Exp $ +.\" $OpenBSD: ntpctl.8,v 1.8 2015/03/11 19:38:48 jmc Exp $ .\" .\" Copyright (c) 2012 Mike Miller .\" @@ -14,7 +14,7 @@ .\" AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT .\" OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: February 10 2015 $ +.Dd $Mdocdate: March 11 2015 $ .Dt NTPCTL 8 .Os .Sh NAME @@ -22,7 +22,7 @@ .Nd control the Network Time Protocol daemon .Sh SYNOPSIS .Nm ntpctl -.Op Fl s Cm all | peers | Sensors | status +.Fl s Cm all | peers | Sensors | status .Sh DESCRIPTION The .Nm @@ -30,24 +30,31 @@ program displays information about the running .Xr ntpd 8 daemon. .Pp -The options (which may be abbreviated) are as follows: +The options are as follows: .Bl -tag -width "-s modifierX" -.It Fl s Cm all -Show all data. -.It Fl s Cm peers -Show the following information about each peer: weight, trustlevel, +.It Fl s Cm all | peers | Sensors | status +Used to display information about the running daemon. +Keywords may be abbreviated. +.Pp +.Cm all +shows all data available. +.Pp +.Cm peers +shows the following information about each peer: weight, trustlevel, stratum, number of seconds until the next poll, polling interval in seconds, and offset, network delay and network jitter in milliseconds. When the system clock is synced to a peer, an asterisk is displayed to the left of the weight column for that peer. -.It Fl s Cm Sensors -Show the following information about each sensor: weight, sensor "good" +.Pp +.Cm Sensors +shows the following information about each sensor: weight, sensor "good" status, stratum, and offset and the configured correction in milliseconds. When the system clock is synced to a sensor, an asterisk is displayed to the left of the weight column for that sensor. -.It Fl s Cm status -Show the status of peers and sensors, and whether the system clock is synced. +.Pp +.Cm status +shows the status of peers and sensors, and whether the system clock is synced. When the system clock is synced, the stratum is displayed. When the system clock is not synced, the offset of the system clock, as reported by the diff --git a/src/usr.sbin/ntpd/ntpd.c b/src/usr.sbin/ntpd/ntpd.c index 283a3086..b0ef5869 100644 --- a/src/usr.sbin/ntpd/ntpd.c +++ b/src/usr.sbin/ntpd/ntpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ntpd.c,v 1.92 2015/02/11 03:16:57 reyk Exp $ */ +/* $OpenBSD: ntpd.c,v 1.93 2015/03/11 19:38:48 jmc Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer @@ -90,7 +90,7 @@ usage(void) if (strcmp(__progname, "ntpctl") == 0) fprintf(stderr, - "usage: ntpctl [-s all | peers | Sensors | status]\n"); + "usage: ntpctl -s all | peers | Sensors | status\n"); else fprintf(stderr, "usage: %s [-dnSsv] [-f file]\n", __progname);