Setting time on ESXi hosts through PowerCLI | Geaux Virtual
4 November, 2013
Excellent powershell to set the correct time on a number of hosts…
I expanded the code to:
Get-Cluster -Name “Cluster” | Get-VMHost | Where-Object {
$t = Get-Date
$dst = $_ | %{ Get-View $_.ExtensionData.ConfigManager.DateTimeSystem }
$dst.UpdateDateTime((Get-Date($t.ToUniversalTime()) -format u))
}
via Setting time on ESXi hosts through PowerCLI | Geaux Virtual.