Não consegui encontrar nenhum host ESXi exibindo várias datas. Você poderia postar seu script inteiro?
Abaixo está um script PowerCLI para mostrar a distorção de tempo entre os hosts da estação de trabalho, do vcenter e do ESXi. Estou curioso para ver a saída contra seus hosts com vários timestamps:
Clear-Host
$ErrorActionPreference = "Continue"
$DebugPreference = "SilentlyContinue"
$VerbosePreference = "SilentlyContinue"
@"
## get_TIMEDRIFT.ps1 ##########################################################
Usage: powershell -ExecutionPolicy Bypass -File ./get_TIMEDRIFT.ps1
Version: 1.0 (20140915)
Purpose: Quickly Display time-drift between Workstation, vCenter, and ESXi
hosts. For the purpose of finding ESXi hosts which can cause
issues if VMs are set to sync time through VMware Tools.
vCAC/IAAS servers will not work propertly if not in sync with SSO
Requirements: Windows Powershell and running on machine with VI Tools/powercli
History: 09/15/2014 - Created
###############################################################################
"@
## Virtual Center Server to test for time-drift against.
$VCServer = "VCEN.TEST.LOCAL"
## If running PS1 script from Powershell instead of PowerCLI, load vcen snap-in
$SIval = Get-PSSnapin -Name VMware.VimAutomation.Core '
-ErrorAction SilentlyContinue
if (($SIval) -eq $null) { Add-PSSnapin VMware.VimAutomation.Core }
## Logon to vCenter Server, will prompt for name/password if not saved.
Set-PowerCLIConfiguration -InvalidCertificateAction Ignore '
-Scope Session '
-Confirm:$false
$VC = Connect-VIServer $VCServer
Write-Output "Connected to '$($VC.Name):$($VC.port)' as '$($VC.User)'"
## Get vCenter and LocalSystem timestamps and drift
# get LocalSystem time
$_localtime = Get-Date
$_localtimeUTC = $_localtime.ToUniversalTime()
# get vCenter time
$_vctime = $VC.ExtensionData.ServerClock
$_vctimeUTC = $_vctime.ToUniversalTime()
# determine time drift between LocalSystem and vCenter
$_localdrift = ($_localtimeUTC - $_vctimeUTC).duration()
## Loop through ESX hosts writing output for each
$vmhosts = Get-VMHost
foreach($esx in $vmhosts){
$esxview = Get-View -viewtype "HostSystem" -Filter @{"Name" = $esx.Name}
$esxdatetimesystem = $esxview.configmanager.datetimesystem
$_remote = Get-View -Id $esxdatetimesystem
$_remotetime = $_remote.QueryDateTime()
$_remotetimeUTC = $_remotetime.ToUniversalTime()
$_vctime = $VC.ExtensionData.ServerClock
$_vctimeUTC = $_vctime.ToUniversalTime()
$_remotedrift = ($_remotetimeUTC - $_vctimeUTC).duration()
Write-Output " $esx Time drift from vCenter in minutes:: '$($_remotedrift.Totalminutes)'"
}
## Ouput timestamps for Local Workstation, and vCenter Server
Write-Output " vCenter Server UTC:: $_vctime"
Write-Output " Workstation (Actual | UTC):: $_localtime | $_localtimeUTC"
Write-Output " Local workstation Time drift from vCenter in minutes:: '$($_localdrift.Totalminutes)'"
## Disconnect user from vCenter Server
Write-Output "Disconnecting '$($VC.User)' from '$($VC.Name):$($VC.port)'"
Disconnect-VIServer $VC -Confirm:$false
Exemplo de saída abaixo:
Connected to 'VCEN.TEST.LOCAL:443' as 'TEST\FMLast'
192.168.15.149 Time drift from vCenter in minutes:: '10280.9866862833'
192.168.15.159 Time drift from vCenter in minutes:: '10281.0125832833'
192.168.15.167 Time drift from vCenter in minutes:: '10281.0392954333'
192.168.15.168 Time drift from vCenter in minutes:: '10281.0690222667'
192.168.15.26 Time drift from vCenter in minutes:: '10281.0986537667'
192.168.15.24 Time drift from vCenter in minutes:: '10281.1276888833'
192.168.15.25 Time drift from vCenter in minutes:: '10281.1569679333'
192.168.15.22 Time drift from vCenter in minutes:: '10281.1863135333'
192.168.15.27 Time drift from vCenter in minutes:: '10281.2183166667'
192.168.15.23 Time drift from vCenter in minutes:: '10281.246763'
vCenter Server UTC:: 09/08/2014 16:38:04
Workstation (Actual | UTC):: 09/15/2014 15:59:01 | 09/15/2014 19:59:01
Local workstation Time drift from vCenter in minutes:: '10280.9408839317'
Disconnecting 'TEST\FMLast' from 'VCEN.TEST.LOCAL:443'