[CentOS] system clock

Sun Feb 6 21:57:04 UTC 2011
Benjamin Franz <jfranz at freerun.com>

On 02/06/2011 01:35 PM, Buz Davis wrote:
> I am running CntOS 5 with Gnome.  Every  now and then I have noticed
> that the computer will somehow get the time wrong by several hours.  Is
> there a simple way to adjust the time?  So far the only way I have found
> is to boot into windows (it is a dual boot system), make the change
> there, and then get back into CentOS.

[...]

CentOS likes to store the hardware system clock in GMT time. Windows 
likes to store it in the local time zone. The multi-hour switch is an 
artifact of dual booting with this disparity in play. If either system 
updates the hardware clock while running, the other OS will get thrown 
off by several hours.

The fastest way to 'resync' the clock is using the ntpdate utiltity. It 
is part of the 'ntp' package. As root run: 'yum install ntp'. You can 
then reset the clock in CentOS by running 'ntpdate' as root.

-- 
Benjamin Franz