VMware Cloud Community
TonyJK
Enthusiast
Enthusiast
Jump to solution

Time sychronizatoin with BIOS for ESX Hosts ?

We are connecting to external NTP server for ESX Hosts. All VMs are sychronized with the ESX Hosts via set up in VMWare Tools.

Howerver, a fellow suggests that we should also synchronize the time with BIOS Clock.

We would like to know

1) Why we have to do so ?

2) What is the command to be used ?

Thanks

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
Rumple
Virtuoso
Virtuoso
Jump to solution

Because the bios is not synchronized with anything. You set it in the bios and it keeps time by the battery. The sync is just like in windows computers. You set the time in Windows and it keeps the BIOS clock in sync incase the battery is low, etc

View solution in original post

0 Kudos
4 Replies
Rumple
Virtuoso
Virtuoso
Jump to solution

I wonder if your Fellow was refering to this. Basically once your ESX server sync's with the NTP server you sync your BIOS with the ESX host time.

Now you can set the local hardware clock to the NTP synchronized local system time. Run:

hwclock --systohc

TonyJK
Enthusiast
Enthusiast
Jump to solution

Hi,

It is exactly the command he suggests to run.

As you have mentioned, the BIOS clock should be synchronized by itself, why does VMWare still recommends running that command OR local hardware clock <> BIOS clock ?

Thanks

Message was edited by: TonyJK

0 Kudos
Rumple
Virtuoso
Virtuoso
Jump to solution

Because the bios is not synchronized with anything. You set it in the bios and it keeps time by the battery. The sync is just like in windows computers. You set the time in Windows and it keeps the BIOS clock in sync incase the battery is low, etc

0 Kudos
mike_laspina
Champion
Champion
Jump to solution

Hello,

There is nothing more you need to do.

The rc0.d shutdown/reboot runlevel will sync the NTP sync'd running clock to the RTC hardware clock.

So it always sets the hardware clock to the last sync'd value when shutting down or rebooting.

Here is the actual script that is run

  1. crond Start/Stop the cron clock daemon.

sync_hwclock() {

if ; then

. /etc/sysconfig/clock

  1. convert old style clock config to new values

action $"Syncing hardware clock to system time" /sbin/hwclock $CLOCKFLAGS

[ "$SYNC_HWCLOCK" = "yes" ] && sync_hwclock

  1. Sync the system clock.

if ; then

. /etc/sysconfig/clock

  1. convert old style clock config to new values

runcmd $"Syncing hardware clock to system time" /sbin/hwclock --directisa $CLOCKFLAGS

http://blog.laspina.ca/ vExpert 2009