vicfg-ntp - configure the NTP server
vicfg-ntp [connection_options] [--add <name_or_IP> | --delete <name_or_IP | --help | --list | --start | --stop | --vihost <esx_host>]
The vicfg-ntp command supports specifying the NTP (Network Time Protocol) server for an ESX/ESXi host. Some protocols, such as Kerberos, must have accurate information about the current time.
Adds the specified NTP server. You can use the name or IP address to specify the NTP server (IPv6 address valid for vSphere 4.0 and later).
Specifies the target server and authentication information if required. Run vicfg-ntp --help
for a list of all connection options.
Deletes the specified NTP server. You can use the name or IP address to specify the NTP server (IPv6 address valid for vSphere 4.0 and later).
Prints a help message for each command-specific and each connection option. Calling the script with no arguments or with --help has the same effect.
Displays all NTP servers used by the host.
Starts the NTP service on the target host.
Stops the NTP service on the target host.
When you run a vCLI command with the --server
option pointing to a
vCenter Server system, use --vihost
to specify the ESX/ESXi host to run the command against.
The following examples assume you are specifying connection options, either
explicitly or, for example, by specifying the server, user name, and password.
Run vicfg-ntp --help
for a list of common options including connection options.
Display the list of NTP servers used by this host:
vicfg-ntp --server <server name> --username <user name> --password <password> --list
Add a remote NTP server with the specified host name or IP address:
vicfg-ntp --server <server name> --username <user name> --password <password> --add <ntp-server>
Delete the remote NTP server with the specified host name or IP address:
vicfg-ntp --server <server name> --username <user name> --password <password> --delete <ntp-server>
Start the NTP service on the host:
vicfg-ntp --server <server name> --username <user name> --password <password> --start
Stop the NTP service on the host:
vicfg-ntp --server <server name> --username <user name> --password <password> --stop