Forrest logo
back to the ntpq tool

ntpq:tldr:0f094

ntpq: Print a list of NTP peers without resolving hostnames from IP addresses.
$ ntpq --numeric --peers
try on your machine

The command "ntpq --numeric --peers" is used to display information about NTP (Network Time Protocol) peers in a machine-readable numeric format.

Here is a breakdown of the command and its options:

  • "ntpq" is the command-line utility for querying and configuring NTP servers.
  • "--numeric" is an option that instructs ntpq to display information in numeric format instead of resolving hostnames. This means IP addresses will be shown instead of corresponding hostnames for the NTP peers.
  • "--peers" is an option that tells ntpq to display information about the NTP peers. NTP peers are other servers or devices that the NTP daemon on the system is synchronizing time with.

When you run this command, it will output information about the NTP peers in a tabular format. The columns typically include the IP address or hostname of the peer, the reference ID of the peer (a unique identifier), the stratum level (how far the peer is from a reference clock), the type of peer (remote server or local clock), the reachability (the success of reaching the peer), and the delay, offset, and jitter values that measure the time synchronization quality.

By using the "--numeric" and "--peers" options together, you can get a concise and machine-readable view of the NTP peers' information.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the ntpq tool