Bug 77818

Summary: time error if /etc/localtime is a symlink
Product: [Retired] Red Hat Linux Reporter: Need Real Name <medbi01>
Component: initscriptsAssignee: Bill Nottingham <notting>
Status: CLOSED NOTABUG QA Contact: Brock Organ <borgan>
Severity: low Docs Contact:
Priority: medium    
Version: 7.3CC: rvokal
Target Milestone: ---   
Target Release: ---   
Hardware: i586   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2002-11-14 00:55:40 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Need Real Name 2002-11-14 00:55:33 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows 98; T312461)

Description of problem:
If /etc/localtime is a symlink to /usr/share/zoneinfo/America/Vancouver then 
when the system comes up it seems to take the time as UTC instead of PST (and 
so drops 8 hours).  If it is a copy of the file then all is well.  This has 
only recently started happening after months of correct operation (at least it 
seemed to be working correctly).
More specifically (and confusingly).  At the point in /etc/rc.d/rc.sysinit 
where hwclock and date are run I have confirmed that the flags passed to 
hwclock are "--hctosys --localtime" but the result of the "date" command 
displays the correct date and time, except it states that the time is UTC 
instead of PST.  By the time that the initialisation is complete and I get the 
chance to log in "date" returns a time 8 hours earlier but now states that the 
time is PST rather than UTC.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.ln -sf /usr/share/zoneinfo/America/Vancouver /etc/localtime
2.shutdown -r now
3.
	

Actual Results:  As it goes through the initialisation I see
Setting clock (localtime) : <whatever> UTC

Expected Results:  As it goes through the initialisation I expect to see
Setting clock (localtime) : <whatever> PST

Additional info:

The issue for me is that the solutions on the newsgroups generally involve 
using a symlink rather than copying the file.

Comment 1 Bill Nottingham 2002-11-14 00:59:55 UTC
If it's a symlink to /usr, and /usr isn't mounted that early when hwclock sets
the time....

That's why we keep it a file. :)