I am having a tough time getting my Ubuntu Virtual Machine to display the proper time. It is on an ESXi server and the version is 8.10 LTS it came with a virtual appliance for Opsview. I have installed ntp and have it pointed to pool.ntp.org. I think it is working with ntpd because when I try to manaully sync it, it says the NTP socket is in use. I have set the time zone to eastern (which is my time zone) using sudo dkpg-reconfigure tzdata and set the date manaully by entering date mmddhhmmyyyy.ss. I also synced the hardware clock by typing hwclock --systohc and everything works fine.

Here is where the problems begin: upon first reboot the system time jumps 5 hours ahead (this is true every time I reproduce it) but the hardware clock stays in sync. Upon a second reboot the hardware clock moves out of sync five hours with system clock. So now I have both clocks that are five hours ahead. What is going here? Please help me get my clocks synced to the proper time.

additional info: The ESXi is set to the proper time and has 12 other vm's running on the proper time including other ubuntu installs(version 10.10), the opsview appliance is the only vm with 8.10. I open for solutions as well as work arounds, I check the site constantly while I am awake so feel free to ask if you need additional info.


You don't want to run NTP or NTPDATE on a virtual machine. It should get its time from the system clock.

Check the UTC value in /etc/default/rcS. Try setting it from no to yes or vice-versa.

While you are at it add an exit 0 line to /etc/default/ntp. Alternatively set the NTPOPTION value to "-q". This will disable NTP on the virtual server.

  • This whitepaper suggests NTP is an option in certain cases vmware.com/files/pdf/Timekeeping-In-VirtualMachines.pdf – PhilT Apr 30 '12 at 13:53
  • vmware may have some cases where the hardware clock is virtual, and won't have side effects on the real hardware clock. In general, you only want one operating system instance modifying the real hardware clock. – BillThor Apr 30 '12 at 15:11

Have you tried using an NTP server that is on the same Time Zone as you?

Does # /etc/init.d/ntp restart give you the same issue of your hardware clock changing?

  • definitely worth a shot, I guess I can set it to my Domain controller or us.pool.ntp.org. I'll try both when I get into the office tomorrow morning, thanks. – Not Kyle stop stalking me Mar 10 '11 at 23:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.