When using image deployment mechanisms for RDSH and VDI workloads, such as Citrix PVS, Citrix MCS and VMware View Composer, it’s extremely important to reconfigure the Windows Time (w32time) Service to ensure that the LastBootUpTime is accurate. If it’s not accurate, it effects monitoring, the correlation of log data, event triggers, etc.
The default Manual trigger of the Windows Time service is based on domain membership, which seems to cause issues as the image boots and changes name to the correct target name. Without having a deep enough understanding on the inner workings of these technologies, I can only assume that the default trigger of the Windows Time service is not compatible with the way the imaging mechanisms work on boot up to change the computer name and join to an Active Directory computer object. There may be a point during startup where Windows detects that it’s not domain joined and therefore stops the Windows Time service, which seems to throw the time out.
Here’s a screen shot from an image I built in Perth, Australia. Notice how the LastBootUpTime is several hours into the future as Perth is GMT +8.
Here’s a screen shot from an image I built in Saskatoon, Canada. Notice how the LastBootUpTime is several hours into the past as Saskatoon is GMT -6.
So to fix this we simply run a script in the master/gold image to…
- Remove the trigger from the Windows Time (w32time) Service
sc triggerinfo w32time delete
- Set the Windows Time (w32time) Service to start automatically
sc config w32time start= auto
Then the LastBootUpTime is accurate as seen in the following screen shot.
Microsoft provides some different options here. However, I’m documenting this to provide discussion and guidance on how the Windows Time service should be configured for these use cases. From my findings tools such as the Citrix Optimizer and VMware OS Optimization Tool do not contain changes to this service.
I hope this helps.