For some unknown reason that I’m yet to learn. The VAMI in vCenter Server Appliance 6 has been removed. VAMI is the management interface that you usually connect to on port 5480 for most VMware appliances. Prior to vCenter 6 you could connect to your VCSA appliance on port 5480. In the VAMI you could check that status of the appliance services, change its network settings, perform updates, and change NTP settings.
* If you’re looking for the process on vCenter 7 please click here
It’s this last setting that quickly alerted me to this change shortly after deploying my first VCSA 6. During the initial deployment of my vCenter Appliance I would specify my NTP servers when prompted. During my first two attempts the deployment would error out and fail because my NTP time sources specified were timing out. So on the third attempt I decided to skip the NTP servers and configure them post install.
Here in lies the new way of modifying NTP settings on a vCenter 6 Appliance.
Firstly we need to log into the appliance via SSH or via the console using the root account.
We will be presented with a VMware shell with instructions on how to enable BASH. For this task and many other vCenter tasks the current shell is good enough. From here we can run our NTP commands. If we type ntp followed by the ‘TAB’ key we get a list of ntp commands we can run.
Typing ntp.get lists the current status of NTP and what NTP servers are configured. In this case the status is Down and no servers have been configured.
Command> ntp.get
Config:
Status: Down
Servers:
Command>
As we have no NTP servers listed we can use the ntp.server.set command. This will override any current servers that may also be listed.
Command> ntp.server.set --servers 0.au.pool.ntp.org
Command> ntp.get
Config:
Status: Down
Servers: 0.au.pool.ntp.org
Command>
We now have one NTP time source set. If we wish to make modifications to the list of servers without overriding them we can use the ntp.server.add command.
Command> ntp.server.add --servers 1.au.pool.ntp.org
Command> ntp.get
Config:
Status: Down
Servers: 0.au.pool.ntp.org 1.au.pool.ntp.org
Command>
With our NTP time sources set we now enable and start NTP using the command timesync
Command> timesync.set --mode NTP
Command> timesync.get
Config:
Mode: NTPCommand> ntp.get
Config:
Status: Up
Servers: 0.au.pool.ntp.org 1.au.pool.ntp.org
And that’s really all that is required. Relatively straight forward to perform. From my point of view it’s certainly not as convenient as using the VAMI web portal from previous versions. As mentioned above. I don’t know why it was removed. Perhaps time constraints meant that it will be introduced in a future update. Or perhaps it’s just hidden on a different port I’m not aware of. In any case it would be nice to officially know.
Note; ‘--servers’ above is a double dash.
References
Add or Replace NTP Servers in the vCenter Server Appliance Configuration
thanks!
all the commands needs to have a — instead of –
Regards
Thanks Ali. All commands have a double dash but for some reason WordPress shows them as one long dash. Haven’t figured out how to fix how this is displayed yet.
Thanks a lot!
Any commands to check the NTP time on the VCSA? or resync it?
Yeah, you can check the time on the localhost or the NTP source easily enough. You have to enable the Bash shell (I’ve mentioned how to do that in previous posts). Then you can just use ‘date’ for the localhost time. To check the time on the NTP source type ‘ntpq -c “rv 0 clock” pool.ntp.org’. Change pool.ntp.org to whatever your source is.
NTP server added and showing in ntp.get, but time is not syncing