Linux fix wrong date/time hwclock

If your clock is wrong you might have a wrong hwclock set…

yum install ntp
ntpdate -s it.pool.ntp.org
hwclock -w

on a side note to change the timezone on RHEL 6.x adjust the clock settings config file:

nano -w /etc/sysconfig/clock

set it as you wish:

ZONE="Europe/Rome"

then set the localtime

cp /usr/share/zoneinfo/Europe/Rome /etc/localtime