Jume - My Virtualization Blog
Tricking the VM BIOS RTC to set a time
Remember this one?
You can select the VM BIOS RTC clock to a certain time!!! And that is cool because this is still 'supported' - or at least it's working! It took me some searching and some blog and forum posts are 12 years old!
All you need to do is edit your VM's configuration and add the following lines:
time.synchronize.continue = FALSE
time.synchronize.restore = FALSE
time.synchronize.resume.disk = FALSE
time.synchronize.resume.memory = FALSE
time.synchronize.shrink = FALSE
time.synchronize.tools.startup = FALSE
tools.syncTime = FALSE
and then the final 'most' important one:
rtc.startTime = <Epoch timestamp>
So the Epoch timestamp can be found on https://www.epochconverter.com/
The RTC is short for 'Real Time Clock'. In a physical computer, this is a special chip which keeps the clock even if you power it off. It's powered by a small battery, and these days most of the RTC chips are embedded in the mainboard. VMware has a 'BIOS' in your VM and by default, it sets the RTC in this BIOS-based on the hypervisor time, but as you can see: it can be overwritten.
Other cool stuff?
Yes, if you configure this together with your virtual disk(s) in 'Independent - Nonpersistent' mode, you can simply stop this VM, which discards all writes to disk since you started the virtual machine. Just remember to set this after you installed the OS (or perhaps before if your goal is to test an OS installation). It's like doing a snapshot and reverting - but now you only need to switch off the VM.
Be aware your OS most likely tries to sync time also by default. So ensure to switch that off, or just run the VM without network connections.
When you subscribe to the blog, we will send you an e-mail when there are new updates on the site so you wouldn't miss them.