LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Clock on wrong time (system clock is set to UTC) (https://www.linuxquestions.org/questions/debian-26/clock-on-wrong-time-system-clock-is-set-to-utc-893527/)

yanom 07-24-2011 05:55 PM

Clock on wrong time (system clock is set to UTC)
 
So my BIOS clock is set to UTC and I keep setting the date with
Code:

date -s <time>
and it sets the time... but after a few reboots it resets itself! I tried setting my timezone with
Code:

dpkg-reconfigure tzdata
but it doesn't change the clock. Anyone know how I can get it on the right time? I am in US central time.

Note: It isn't a problem with the clock program, because both the date program and the panel clock show the same (incorrect) time.

kmassare 07-24-2011 06:21 PM

hwclock --systohc

michaelk 07-24-2011 06:37 PM

If you dual boot make sure the hardware clock is set for local time. Also verify/change the config setting so the OS knows the hardware clock is set for local or UTC @ /etc/default/rcS.

yanom 07-25-2011 11:50 AM

Quote:

Originally Posted by michaelk (Post 4424181)
If you dual boot make sure the hardware clock is set for local time.


so I have to update the hardware clock every time daylight savings* comes around?


*the idiot that invented daylight savings should be shot.

michaelk 07-25-2011 12:34 PM

No. Windows expects the hardware clock to be local time. linux will adjust as required but you do have to set the config file for the correct value (UTC or local). And the correct terminology is Daylight Saving Time :)

You did not say if you have a dual boot setup. I assume that your clock is off by 5 hours i.e. the difference between Central DST and UTC.

yanom 07-26-2011 10:46 AM

I do dual-boot. So, I set it to local time, then adjust the config file where?

tredegar 07-26-2011 11:26 AM

michaelk told you where: /etc/default/rcS

If you set UTC=no in that file then the system clock is assumed to be set to local time. See man rcS. This probably needs a reboot to take effect.


All times are GMT -5. The time now is 04:47 PM.