Portal Home > Knowledgebase > VMware Knowledge Base > Enabling remote query of NTP service on ESX/ESXi 4.0

Enabling remote query of NTP service on ESX/ESXi 4.0


This article provides the steps for configuring the NTP service on an ESX/ESXi 4.0 host to allow remote queries. This allows external clients to use ntpq or ntpdc to retrieve server status information, including information on upstream NTP servers that are used for time synchronization. This information may be useful while troubleshooting NTP time synchronization.

These steps are not necessary for other versions of ESX/ESXi, such as 4.1, as those versions permit remote queries by default.

The NTP client tools ntpq and ntpdc may be installed by default on Linux distributions as part of the NTP package. If these command line utilities are not available, see your Linux distribution's documentation.


To configure the ESX/ESXi 4.0 host's NTP daemon to permit remote status queries:

  1. Open a console to the ESX or ESXi host. For more information, see Unable to connect to an ESX host using Secure Shell (SSH) (1003807) or Using Tech Support Mode in ESXi 4.1 and ESXi 5.0 (1017910).

  2. Open the file /etc/ntp.conf in a text editor. For more information, see Editing configuration files in VMware ESX (1017022).

  3. The NTP daemon on ESX/ESXi 4.0 is configured with an entry to restrict access, by default. The entry looks like this:

    restrict default kod nomodify notrap noquery nopeer

    Allow remote queries of the ESX/ESXi NTP daemon's status, by removing the noquery option from that entry. The edited version of the entry looks like this:

    restrict default kod nomodify notrap nopeer

  4. Save the configuration file.

  5. Restart the NTP service on the ESX/ESXi host. Use this command:

    /etc/init.d/ntpd restart

  6. Configure the ESX/ESXi host to synchronize time with a remote NTP server. The NTP daemon does not listen for remote queries until it is configured with an upstream time server and restarted. For more information, see the documentation for your version of ESX/ESXi.

  7. Use the NTP Query utility program ntpq to connected to and remotely query your ESX/ESXi host's NTP server. For more information, see Troubleshooting NTP on ESX and ESXi (1005092).

Based on VMware KB 1036357

Also Read