3

I have set up an EC2 instance, running ArchLinux, for use as a server. Doing what I always do when installing Arch, I try to fix the time by using:

# hwclock --systohc --utc

This does not work, and I get from the system:

hwclock: Cannot access the Hardware Clock via any known method.
hwclock: Use the --debug option to see the details of our search for an access method.

I am pretty sure this has to do with the virtualised nature of EC2 instances.

If anyone could educate me as to what can fix this, I would be grateful. On a different note, what are the implications if I leave the time issue as is and not do anything? Will something malfunction on the server? Will the time go crazy?

dlyk1988
  • 1,644
  • 4
  • 24
  • 36

1 Answers1

1

This thread may be definitely helpful for you. I can see a several seconds drift on my instances (RHEL6, micro instances) as well where I don't run NTP server. EC2 instances used to synchronize their clocks with hypervisor clock. Available clock sources are visible in

/sys/devices/system/clocksource/clocksource0/available_clocksource

The one which is used is in

/sys/devices/system/clocksource/clocksource0/current_clocksource

So if you want more accurate time configure NTP server or run ntpdate client regularly via cron.

dsmsk80
  • 5,757
  • 17
  • 22