NTPVIZ(1)
π NAME π
ntpviz β bestie, it makes visualizations of offset, jitter, etc. from stats file data. That's it, that's the whole name section, slay β¨
This page lives in section 1 of the NTPsec manual, so if you were looking for NTPVIZ(1) β yeah, you're in the right place π
π¦ SYNOPSIS π¦
ntpviz [OPTIONS]
[-c | --clip]
[-D DLVL | --debug DLVL]
[-d LOGDIR[,LOGDIR]...]
[-e endtime]
[-g | --general]
[-h | --help]
[-n NAME | --name NAME]
[-N | --nice]
[-o OUTDIR | --outdir OUTDIR]
[-p DAYS | --period DAYS]
[-s STARTTIME | --starttime STARTTIME]
[-T TERMINAL | --terminal TERMINAL]
[-V | --version]
[-w SIZE | --width SIZE]
[--all-peer-jitters |
--all-peer-offsets |
--local-error |
--local-freq-temps |
--local-gps |
--local-jitter |
--local-offset |
--local-offset-histogram |
--local-offset-multiplot |
--local-stability |
--local-temps |
--peer-jitters=hosts |
--peer-offsets=hosts]
[@OPTIONFILE]
ok so real talk: up there it says-g | --general, and down in the options it says-g or --generate. I am not making that up, that's literally what the page says. Copy-paste it exactly, bestie, don't @ me π
πΈ DESCRIPTION πΈ
ntpviz analyzes files in an NTP log directory and generates statistical plots from them. Iconic behavior, honestly.
It can output either PNG images or the gnuplot programs to generate them to standard output. In its default mode it generates an HTML directory containing an index page and either:
- (a) all plots, for a single statfiles directory, or
- (b) a subset of comparative plots for multiple directories.
π Basic Options π
-cor--clipβ normally all data gets plotted. This option limits the range of the plots to the data between 1% and 99%, which is lowkey perfect for ignoring a few spikes in the data. The way it just βοΈ snips the chaos out.-d LOGDIR[,LOGDIR]...or--datadir LOGDIR[,LOGDIR]...β specifies one or more logfile directories to examine. The default is the single directory/var/log/ntpstats.-D DLVLor--debug DLVLβ set the debug level to DLVL. Bigger DLVL = more verbosity:0is the default: quiet except for all ERRORs and some WARNINGs.1shows some environment info and basic program progress.2leaves the plot file in the system temp directory.9is painfully verbose.9also includes profile data. (She's not okay. She's thriving. Both. π)
-e TIMEor--endtime TIMEβ with-sand-eyou set the start and end times. TIME is either numeric POSIX time (seconds since the start of the epoch) or ISO 8601-style timestamps (yyyy-mmm-ddThh:mm:ss). The default end time is the last logfile entry timestamp. The default start time is computed as the end time minus DAYS. Alternatively, you may specify either-sor-e(but not both) and use-pto set the plot period in days.-gor--generateβ run plot through gnuplot to make png. The default is to generate gnuplot programs.-n STRor--name STRβ set the sitename shown in the plot title, and it's effective only for the single-directory case. The default is the basename of the log directory.-Nor--niceβ run at the lowest possible priority. Only available on UNIX. Give that CPU some space, queen π«Ά-o OUTDIRor--outdir OUTDIRβ set the directory for all output to be OUTDIR; if OUTDIR does not exist it gets created. The default OUTDIR isntpgraphs.
β οΈ Warning: existing PNG files and index.html in the output directory will be clobbered. Gone. Deleted. Not coming back. Back that up, bestie π
-p DAYSor--period DAYSβ the default DAYS is for 7 days. DAYS can be a floating point number, so-p 0.5plots 12 hours. DAYS is ignored if-sand-eare given.-s TIMEor--starttime TIMEβ see-eand-p. That's the whole vibe, go read those β¨-T TERMINALor--terminal TERMINALβ set the gnuplot terminal type for generating the graphs. Supported types aregif,jpg,png,pngcairo, andsvg. The default ispng. Some preferpngcairoorsvg. Aesthetic choices, we love to see it π-Vor--versionβ print program version and exit.-w SIZEor--width SIZEβ set the size of the output plots. SIZE can be one ofs,m, orl:sis for browser on small screens (1024x768).mfor medium screens (1388x768).lfor large screens (1920x1080).mis the default. Main character size π
π Individual Plots π
The plot options choose what graph is generated; invoke only one. By default, the gnuplot for the graph is reported; with -g you get the rendered PNG.
The following plots are available:
--all-peer-jittersβ report all peer jitters. This is a different option name from--peer-jittersonly because of a limitation in the Python standard library. (Not her fault, fr fr.)--all-peer-offsetsβ report all peer offsets. This is a different option name from--peer-offsetsonly because of a minor limitation in the Python standard library.--local-errorβ clock frequency offset from the loop statistics (field 4).--local-freq-tempsβ plot local frequency offset and local temperatures. This plot is only generated if there is a log file namedtempsin the log file directory.--local-jitterβ clock time-jitter plot from the loop statistics (field 5).--local-gpsβ plot GPS Time Dilution of Precision (TDOP) and the number of satellites used (nSats). This plot is only generated if there is a log file namedgpsdin the log file directory. π°οΈ--local-offsetβ clock time and clock frequency offsets from the loop statistics (fields 3 and 4).--local-offset-histogramβ frequency histogram of distinct loopstats time offset values (field 3).--local-offset-multiplotβ plot comparative local offsets for multiple directories.--local-tempsβ plot local temperatures. This plot is only generated if there is a log file namedtempsin the log file directory. π‘οΈ--local-stabilityβ RMS frequency-jitter plot from the loop statistics (field 6); this is deviation from a root-mean-square extrapolation of the moving average of past frequency readings.--peer-jitters=host1[,host2...]β peer jitter from local clock time, from peerstats (field 7). A comma-separated list of peer names must follow. It is a fatal error for any of these names not to appear in peerstats. π--peer-offsets=host1[,host2...]β peer offset from local clock time from peerstats (field 4). A comma-separated list of peer names or IP addresses must follow. It is a fatal error for any of these names not to appear in peerstats.
If no individual plot is specified, all plots and an index HTML page are generated into the output directory.
When an index is generated, ntpviz will look for a header and footer file in the output directory. Neither of these files are required. These files may contain arbitrary HTML.
The header file will be added almost at the top of the body of the generated index page, and the footer file will be added almost at the bottom of the body of the generated index page.
The contents are at the discretion of the operator. One might put links to other related web pages, or notes on the server OS, software versions, hardware configuration, etc. into either of these files, as desired. Cute little DIY corner, obsessed π₯°
The code includes various sanity checks and will bail out with a message to standard error on, for example, missing logfile data required for a plot. She's checking on you. She's also leaving if you don't have the data.
π§ Argument File π§
Any command line options may also be placed into a command file. The command file name (OPTIONFILE) is prefixed on the command line with an atsign (@).
Each line in the command file should contain just one option. Multiple options per line are allowed but discouraged. Blank lines are allowed.
Comments may be added prepended with an octothorpe (#). Comments may appear on a new line, or trailing, after the # .
When an option takes a parameter, the option and parameter must be separated by an equal sign (=) or spaces.
These two ways to invoke ntpviz are equivalent:
$ ntpviz --period 1 --outdir day
$ cat day/config
--period=1
--outdir=day
$ ntpviz @day/config
See? Same girl, different outfit π
β REQUIREMENTS β
Python and gnuplot. The plots will look better with the liberation font package installed. Glow-up optional but recommended β¨
π AUTHORS π
Eric S. Raymond, Gary E. Miller, and Daniel Drown. The gnuplot in this package is largely based on templates in Daniel Drown's chrony-graph project: https://github.com/ddrown/chrony-graph/tree/ntpd
π₯ EXIT STATUS π₯
One of the following exit values will be returned:
0β Successful program execution. Slay. π1β The operation failed, usually due to a missing logfile required for a plot.2β Illegal command-line option.
and that's the whole page, bestie π«Ά this was NTPsec, dated 2026-10-21, and it's giving "concurrently maintained and also iconic." no cap, go plot something pretty ππ
π¦ where this page comes from
- fedora 43: ntpsec 1.2.6-1.fc43 Β· NTP AND BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause AND ISC AND Apache-2.0 AND Beerware
- fedora 43: ntpsec 1.2.6-1.fc43 Β· NTP AND BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause AND ISC AND Apache-2.0 AND Beerware
- fedora 44: ntpsec 1.2.6-1.fc44 Β· NTP AND BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause AND ISC AND Apache-2.0 AND Beerware
- fedora 44: ntpsec 1.2.6-1.fc44 Β· NTP AND BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause AND ISC AND Apache-2.0 AND Beerware
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms