[CentOS] Strange issue with system time being off

Thu Aug 9 23:42:11 UTC 2012
Robert Nichols <rnicholsNOSPAM at comcast.net>

On 08/09/2012 02:33 PM, Russell Jones wrote:
> Hi all,
>
> I am having an issue with some older CentOS 5.3 servers. Every time
> the server boots, it gives the error "Cannot access the hardware clock
> by any known method", and then promptly sets the time 5 hours behind
> the hardware clock, down to the second.
>
> After the system is up. "hwclock" works fine. hwclock --debug does not
> show any error at all.

Apparently something is amiss in the initramfs preventing access to the
rtc, and once the real root filesystem is mounted, rtc access works.  I'm
not sure where to look or how an error might have crept in, but when I
unpack my initramfs on a couple of systems (it's a compressed cpio
archive) and grep for "rtc", I find:

   ./etc/modprobe.d/dist.conf:alias char-major-10-135 rtc
   ./etc/udev/rules.d/50-udev-default.rules:SUBSYSTEM=="rtc", 
DRIVERS=="rtc_cmos", SYMLINK+="rtc"


-- 
Bob Nichols     "NOSPAM" is really part of my email address.
                 Do NOT delete it.