Bug 110672 - localtime() always shows UTC
localtime() always shows UTC
Status: CLOSED NOTABUG
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: ntp (Show other bugs)
3.0
All Linux
medium Severity medium
: ---
: ---
Assigned To: Harald Hoyer
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-11-22 16:25 EST by Brad Smith
Modified: 2007-11-30 17:06 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-07-29 03:55:34 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Brad Smith 2003-11-22 16:25:40 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030922

Description of problem:
The clock applet in the gnome panel only displays UTC time. The system
is set to store time as UTC time. The timezone information is
correctly set. The "date" command at the prompt displays the correct
local time. The adjust time and date dialog for the clock applet also
displays the correct local time. The UTC checkbox is not checked.

Version-Release number of selected component (if applicable):
gnome-panel-2.2.2.1-4

How reproducible:
Always

Steps to Reproduce:
1. set system time to UTC time
2. set timezone
3. applet displays UTC time not local time
    

Actual Results:  UTC time

Expected Results:  Local time

Additional info:
Comment 1 Brad Smith 2003-11-22 19:19:16 EST
I rebooted the system and the display corrected itself to local time
and not UTC time. Apologies for the wasted bandwidth.
Comment 2 Suzanne Hillman 2003-11-24 13:35:21 EST
Closing as NOTABUG based on comment #1
Comment 3 Dimas Moreira Junior 2004-02-07 11:51:54 EST
I'm having the same problem, my system time is not set to UTC but the
applet only displays time in UTC. Reboot doesn't solve the problem.
Comment 4 Dimas Moreira Junior 2004-02-09 09:55:44 EST
After several reboots the clock is working correctly again. But I'm
sure there is something wrong with it, I´ll perform another
installation, see what happens and report back.
Comment 5 Warren Togami 2004-06-17 02:40:03 EDT
We are seeing this bug in a fresh install of RHEL3 U2 in the Brisbane
office.  Very frustrating.  It isn't the clock's fault though, because
outgoing mail from Evolution has the wrong time of day too.
Comment 6 Warren Togami 2004-06-17 02:51:32 EDT
Sarah said that it was fine on her RHEL3 U2 install for a day, until
she enabled ntp to automatically sync time, and subsequently it was
problematic.  Investigating further...
Comment 7 Warren Togami 2004-06-17 20:22:07 EDT
Sarah disabled ntp and it returned back to normal.  I am unable to
reproduce this problem on an identical RHEL3 U2 install on vmware. 
This is either a problem with glibc, or more likely the configuration
tools.
Comment 8 Harald Hoyer 2004-07-13 11:43:41 EDT
what is in /etc/sysconfig/clock ??
Comment 9 Harald Hoyer 2004-07-13 11:46:05 EDT
how do you set your timezone?
# /usr/sbin/timeconfig
should be used...
Comment 10 Warren Togami 2004-07-13 18:41:12 EDT
Sarah is unwilling to subject her personal laptop to testing, so until
we manage to reproduce this on another box we cannot debug it. =(
Comment 11 Brad Smith 2004-07-14 22:08:41 EDT
Contents of /etc/sysconfig/clock on my system:

ZONE="America/Vancouver"
UTC=true
ARC=false
Comment 12 Tom Webster 2004-07-27 16:17:16 EDT
We have seen this, or something much like it, on fresh RHEL3 installs
with timezone set to PST and an NTP timeserver setup.  Both on GUI
installs and on kickstart installs.  Going back with the dateconfig
and setting the TZ to something different and then setting it back
seems to resolve the problem for us.

In all cases, the system hardware clock is running UTC and the system
is configured to connect to a V3 (no encryption) NTP server for syncro.
Comment 13 Harald Hoyer 2004-07-28 03:22:48 EDT
/etc/localtime may have the wrong permissions.
Please check, that it is readable by any user!
Comment 14 Brad Smith 2004-07-28 22:08:45 EDT
[bgsmith@pico bgsmith]$ ls -l /etc/localtime
-rw-r--r--    1 root     root         1037 May 17 19:34 /etc/localtime


I should note that on my system (rhel 3) this is no longer an issue. I
apologize that I cannot recall what I did, or what was done to correct
the problem.

Brad

Note You need to log in before you can comment on or make changes to this bug.