hardware clock and utc, etc...
Hello guys. I have some problem. How can i set my RTC to UTC? in rc.conf: TIMEZONE=Europe/Kiev The problem is actually in the fact, that when i do # hwclock --utc --systohc, then RTC is setups in localtime minus 3 hours. But when i do hwclock --utc --hctosys, then my sys time is the same as in RTC. How can i configure my RTC to UTC and have correct localtime? (I know about /etc/adjtime and rc:79 hwclock --hctosys and rc.shutdown:37 hwclock --systohc) If i setup my RTC to 10:00:00 (say, from BIOS). And the last line of /etc/adjtime is UTC, then when i boot up CRUX, i have localtime set to 10:00:00, but when i do shutdown, then my RTC sets to 7:00:00. (... then bootup - 7:00:00, shutdown - 4:00:00) So, i get 3 hours time shift... How can I avoid this? And how cat I properly set my RTC to UTC? PS: I have CRUX-2.5 and util-linux-ng-2.16.1 Thanks for your attension, time and ansvers. And sorry me for my horrible english.
On Fri, Sep 18, 2009 at 02:04:59PM +0300, Vasylchyshyn Nikolay wrote:
Hello guys.
Hello,
I have some problem. How can i set my RTC to UTC?
in rc.conf: TIMEZONE=Europe/Kiev
The problem is actually in the fact, that when i do # hwclock --utc --systohc, then RTC is setups in localtime minus 3 hours. But when i do hwclock --utc --hctosys, then my sys time is the same as in RTC.
That's wrong, if you have your TIMEZONE set in rc.conf and, more important, your /etc/localtime is a valid symlink to /usr/share/zoneinfo/Europe/Kiev than your systime should be RTC time + 3 hours.
How can i configure my RTC to UTC and have correct localtime? (I know about /etc/adjtime and rc:79 hwclock --hctosys and rc.shutdown:37 hwclock --systohc)
If i setup my RTC to 10:00:00 (say, from BIOS). And the last line of /etc/adjtime is UTC, then when i boot up CRUX, i have localtime set to 10:00:00, but when i do shutdown, then my RTC sets to 7:00:00. (... then bootup - 7:00:00, shutdown - 4:00:00) So, i get 3 hours time shift... How can I avoid this?
And how cat I properly set my RTC to UTC?
- verify the /etc/localtime symlink - set your systime to the correct localtime, best with rdate - run 'hwclock --utc --systohc' HTH and best regards Juergen -- Juergen Daubert | mailto:jue@jue.li Korb, Germany | http://jue.li/crux
Juergen Daubert wrote:
On Fri, Sep 18, 2009 at 02:04:59PM +0300, Vasylchyshyn Nikolay wrote:
Hello guys.
Hi,
Hello,
I have some problem. How can i set my RTC to UTC?
in rc.conf: TIMEZONE=Europe/Kiev
The problem is actually in the fact, that when i do # hwclock --utc --systohc, then RTC is setups in localtime minus 3 hours. But when i do hwclock --utc --hctosys, then my sys time is the same as in RTC.
That's wrong, if you have your TIMEZONE set in rc.conf and, more important, your /etc/localtime is a valid symlink to /usr/share/zoneinfo/Europe/Kiev than your systime should be RTC time + 3 hours.
How can i configure my RTC to UTC and have correct localtime? (I know about /etc/adjtime and rc:79 hwclock --hctosys and rc.shutdown:37 hwclock --systohc)
If i setup my RTC to 10:00:00 (say, from BIOS). And the last line of /etc/adjtime is UTC, then when i boot up CRUX, i have localtime set to 10:00:00, but when i do shutdown, then my RTC sets to 7:00:00. (... then bootup - 7:00:00, shutdown - 4:00:00) So, i get 3 hours time shift... How can I avoid this?
And how cat I properly set my RTC to UTC?
- verify the /etc/localtime symlink - set your systime to the correct localtime, best with rdate - run 'hwclock --utc --systohc'
Also if you dual boot be sure the other systems are correct to.
HTH and best regards Juergen
Danny
participants (3)
-
Danny Rawlins
-
Juergen Daubert
-
Vasylchyshyn Nikolay