# ntpsweep - print information about NTP servers

| from The Sorcerer’s Apprentice, Walt Disney A new broom sweeps clean.

## 1. Manual Pages

### 1.1. Manual Pages

- ntp.conf(5) - ntpd Configuration File

- ntp.keys(5) - NTP symmetric key file format

- ntpd(8) - Network Time Protocol (NTP) daemon

- ntpdig(1) - Simple Network Time Protocol (SNTP) client

- ntpfrob(8) - frob the local clock hardware

- ntpkeygen(8) - generate public and private keys

- ntpleapfetch(8) fetch and manage leap-offset file

- ntploggps(1) - log gpsd data for use by ntpviz

- ntplogtemp(1) - log system temperature data for use by ntpviz

- ntpmon(1) - real-time NTP status monitor

- ntpq(1) - standard NTP query program

- ntpsnmp(1) - an AgentX Simple Network Management Protocol sub-agent [experimental]

- ntpsweep(1) - print information about given NTP servers

- ntptime(8) - read and set kernel time variables

- ntptrace(1) - trace a chain of NTP servers back to the primary source

- ntpviz(1) - make offset, jitter, and other plots from logfiles

- ntpwait(8) - wait until ntpd is in synchronized state

## 2. Table of Contents

- Synopsis

- Description

- Options

## 3. Synopsis

ntpsweep [-V | --version] [-l host]… [-p] [-m number] [-s prefix] [-h string] [hostfile…]

## 4. Description

ntpsweep prints per host the NTP stratum level, the clock offset in seconds, the daemon version, the operating system and the processor. Optionally recursing through all peers.

If no hosts are specified, ntpsweep reports on localhost.

ntpsweep relies on ntpq and Mode 6 queries to probe servers. This depends on the remote host’s restrict configuration allowing queries. Nowadays effectively all public hosts set noquery, so this script is unlikely to be useful unless you have multiple specially- configured timeservers on a LAN.

## 5. Options

-l string, --host-list=string

  Host to execute actions on. This option may appear an unlimited number of times.

  Use this option to specify the host on which this script operates. May appear multiple times. Multiple hosts may be specified, delimited by commas.

-p, --peers

  Recursively list all peers a host synchronizes to.

-m number, --maxlevel=number

  Traverse peers up to this level (4 is a reasonable number). This option takes an integer number as its argument.

-s string, --strip=string

  Strip this string from hostnames.

-h string, --host=string

  Specify a single host. Deprecated option for backwards compatibility.

-V, --version

  Print the version string and exit.

If hostfiles are specified, they are treated as lists of hostnames to be swept, one per line.

Home Page | Site Map | Contacts