Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

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 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 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.

share|improve this question
up vote 1 down vote accepted

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.

share|improve this answer
This whitepaper suggests NTP is an option in certain cases – 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?

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

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .