LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Linux OS Clock/Timezone shows the clock off by 6 hours between OS's (http://www.linuxquestions.org/questions/linux-software-2/linux-os-clock-timezone-shows-the-clock-off-by-6-hours-between-oss-430727/)

JBailey742 04-01-2006 02:58 PM

Linux OS Clock/Timezone shows the clock off by 6 hours between OS's
 
I'm in central, which is -600. When I'm using a Linux OS, at noon, I see 12:00.
No Problem. When I switch to another OS, Linux based or Windows, I see 18:00 (6:00 pm).
I was told to enter the Linux timezone to "UTC".
When I switch from Linux to Linux/Windows, and back to Linux, it's all the same time.
Problem solved.
However, my email in Linux anyway, is now set to 6 hours past the actual time.

So, in a sense, I'm still dealing with this 6 hours difference.

How can this be solved?

Randux 04-01-2006 04:06 PM

*doze causes the problem by saving the local time on your machine (BIOS). You set up *doze to display the local time by setting your timezone in start->control panel->date/time.

on Linux you have a timezone correction - you also set your local timezone (not UTC) and maybe also tell it that your hardware clock is on local time (not UTC). These are the two confusing things.

If you don't run *bloze you can set your clock to GMT and use offsets like real operating systems use. If you do run it, it's going to keep changing your clocks back to local time, which will screw up Linux unless you set a local time zone in Linux.

JBailey742 04-02-2006 08:48 PM

so, what really is the solution? I have both set to local time (central), and one is 6 hours ahead.
If I set one to UTC, the email is off by 6 hours.
Unless I can play Descent and Call of Duty 2 on mandriva, I'm sort of dependant on windows XP

shane_kerr 04-03-2006 03:01 AM

The solution depends on the distribution
 
Most distributions have a way to configure whether the computer clock uses the local time or UTC.

Windows always uses the local time, so for machines that have both Windows and Linux, you should set this to local time.

For instance, on Gentoo there is a file called /etc/conf.d/clock, that contains some lines like this:
Code:

# Set CLOCK to "UTC" if your system clock is set to UTC (also known as
# Greenwich Mean Time).  If your clock is set to the local time, then
# set CLOCK to "local".  Note that if you dual boot with Windows, then
# you should set it to "local".

CLOCK="local"

Google is your friend here. Try something like "YOUR_DISTRIBUTION local timezone".

ceti 04-03-2006 07:19 AM

JBailey742:

1 - from a terminal, as root, type:
date MMDDhhmmYYYY
Ex: if it's 13:42 in your city, type:
date 040313422006

then type:
2 - tzconfig
3 - 12
4 - Universal

I think this will fix it (well, I use Kubuntu).

Dominique_71 04-03-2006 02:11 PM

You must use UCT. On gentoo, it is in the file /etc/adjtime, but it can differ with other linux flavor. On windows, I don't remember, but it is possible. Of course, both must use UTC.

KimVette 04-03-2006 02:44 PM

Use Local Time to avoid the Windows confusion on a dual boot. I keep my BIOS set to local time, Linux configured to local time, then on the rare occasion that I need to reboot to Windows everything is kosher.

JBailey742 04-03-2006 05:44 PM

I'm using Mandriva 2006

JBailey742 04-05-2006 09:56 PM

I'll try to be as detailed as I can be.
First of all, I'm using MandrivaLinux 2006 and Windows XP Home Edition.

If I have both OS's as local time (Central), and have set Linux to the right time (let's say 12:00), Windows XP will say 18:00 (6:00 pm).
Resetting Windows time doesn't do any good, for it will be back at 18:00 when I reboot back to Windows.

If I set Linuxs OS to UCT, both Linux and Windows XP will display 12:00.
However, at least for Linux, the time the emails are being received and sent, are now 6 hours past the actual time.

One way or another, I'm facing some 6 hour difference (6 of course being -600)

vectordrake 04-06-2006 11:40 PM

Try the recommendation in the Mandriva Wiki on this page in the section entitled "Time Zones And Setting Time" to set your clock properly. Its a pretty decent explanation of how to do it with Mandriva and the tzselect and hwclock functions.

To get along with Windows, you'll need to set your clock to localtime, not UTC.


All times are GMT -5. The time now is 08:38 AM.