Hi
i have a prolem .
i have more than 100 virtual machine on my esxi host 5.1 i added ntp server and in Configuration Tab / time configuration my time and date is ok but when i create new virtual machine and installed on Vmwae tools and tik this box synchronize guest time with host but time of my virtual machine is not sync with esxi
how can solve yhis problem?
Best regards
Babak
Please use this help page : Configure Time Synchronization Between Guest and Host Operating Systems . Let me know if it solves the issue
i have seen this document previously but i have more than 100 virtual machine and vmware tools is installed on all of them but time is not sync and login in to more than 100 vms is so difficult i want know is there any solution without login in to virtual machines doing time synchronization between esxi host and vms ? means all of my virtual machines get time from my esxi
If the "synchronize guest time with host" checkbox is enabled on the vSphere Client, you can use this powerCLI command : get-view -viewtype virtualmachine -Filter @{'Config.Tools.SyncTimeWithHost'='True'} | select name
what is the output of this command and what do this command do ? what change?
The above command list the VMs which has "synchronize guest time with host" option enabled. Please see the option in the edit settings(attached snapshot).
To enable this option you can use the powerCLI script after logging in to the vSphere client using powerCLI:
$VMGuests = Get-VM
ForEach ($VMGuest in $VMGuests) {
$obj = New-Object VMware.Vim.VirtualMachineConfigSpec
$obj.changeVersion = $VMGuest.ExtensionData.Config.ChangeVersion
$obj.tools = New-Object VMWare.Vim.ToolsConfigInfo
$obj.tools.syncTimeWithHost = $true
$MyVM = Get-View -Id $VMGuest.Id
$MyVM.ReconfigVM_Task($obj)
}
i have done manually enable this opton on vm edit setting but virtual machine time is not sync with esxi host
now i confused is that helpfull to use this command?
ForEach ($VMGuest in $VMGuests) {
$obj = New-Object VMware.Vim.VirtualMachineConfigSpec
$obj.changeVersion = $VMGuest.ExtensionData.Config.ChangeVersion
$obj.tools = New-Object VMWare.Vim.ToolsConfigInfo
$obj.tools.syncTimeWithHost = $true
$MyVM = Get-View -Id $VMGuest.Id
$MyVM.ReconfigVM_Task($obj)
}
just i copy and paste this in powecli ?
Yes, you can copy-paste to powerCLI prompt and press enter twice. It works.
Verify whether the host and the VM are in the same timezone.
i am confused i want sync my vms time with esxi host without login to my virtual machines and chnage timezone or ..... but you say the host and the VM are in the same timezone i don't want login to machines i have just installed vmware tools on my machines can i sync all of my vms with esxi host without login to vms and change manually?