In order to enable a VMGuest to sync time with an ESX Host, the following line needs to be enabled in the VMX file: tools.syncTime = "TRUE"
Windows Guests:
Login, click on the vmware tools icon in the system tray, options tab, and select the Time Synchronization between the virtual machine and the console operating system option.
Close Vmware tools properties.
Logoff.
Linux Guests:
Login.
start the Xserver (off to a bad start already)
launch the vmware-toolbox application which requires XWindows, click on the Time Synchronization between the virtual machine and the console operating system option.
exit vmware-toolbox
shutdown Xserver
logoff.
Request:
Command line option to enable the tools.syncTime = "TRUE" feature in the vmx file from within the guest, just as these check boxes do. We'd like this option to be available for both Windows and Linux vmware-tools.
Justification:
\* When we do upgrades, make setting changes, or otherwise manage our guest environment, we want to script as much as possible and avoid logons.
\* We do not wish to or run X windows on our Linux systems.
\* We wish to allow junior admins to deploy Linux or Windows VMguests who do not have access to the .vmx files on the ESX server.
\* Manual edits of the .vmx file each time the VMguest is built is not desirable.
I'm not in front of a box to test right now, but try this:
Re: enable VMGuest time sync with ESX host via vmware tools command line opvmware-cmd myVM.vmx setconfig tools.syncTime TRUE[/code]
Hi Ken,
Thank you for your reply, but vmware-cmd runs on the ESX host, not within a guest. The action needs to occur within the guest, just as checking the box occurs within the guest.
Thank you.
wilson
As it turns out there is some documentation for this in the workstation 6 beta. I will try this and post the results. I figured I'd post this now, in the event that anyone else gets to it before I can repost.
Finally got around to updating this thread. VMware workstation 6 has been GA for a bit, and the following is in that documentation (Start at Page 145). I have not checked to see if it is included in ESX 3.0.2 documentation.
In order to enable or disable Vmware Tools time sync, the .vmx file needs to be adjusted. In order to do this and have it take effect without a power off/power on operation, one has to do this from the guest.
There are two options for this. The first is to open the vmware tools icon in windows (or the vmware-toolbox X application in GNU/Linux) and select or deselect the time sync option.
The other, and what I was looking for at the start of this thread is the command line method.
For windows, use vmwareservice.exe for linux, use vmware-guestd. The command requires that you specify both the current and the future value correctly for this to work :
vmwareservice (or vmware-guestd) --cmd "vmx.set_option synctime " where 0 denotes FALSE and 1 denotes TRUE.
SO for example,
Windows:
enable VMware time sync where it was previously disabled:
vmwareservice --cmd "vmx.set_option synctime 0 1"
...and to turn it back off:
vmwareservice --cmd "vmx.set_option synctime 1 0"
GNU/Linux:
turn it on...
vmware-guestd --cmd "vmx.set_option synctime 0 1"
...and turn it back off:
vmware-guestd --cmd "vmx.set_option synctime 1 0"
GREAT !!!
Is there a way to enable/disable
time.synchronize.continue
time.synchronize.restore time.synchronize.resume.disk time.synchronize.shrink time.synchronize.tools.startup If I try for example vmservice --cmd "vmx.set_option time.synchronize.restore 1 0" its returning Unknown option name Thanks mumtaz