Bug 1297578

Summary: timezone Sydney Australia wrong
Product: [Fedora] Fedora Reporter: George <george.seaton>
Component: tzdataAssignee: Patsy Griffin <pfrankli>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: fweimer, george.seaton, me, pfrankli
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-02-29 05:15:45 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
date.log none

Description George 2016-01-11 22:43:58 UTC
Description of problem:


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


How reproducible:


Steps to Reproduce:
1.Desktop Clock is wrong
2.
3.

Actual results:


Expected results:
Desktop Clock is correct

Additional info:
Timezone appears to be UTC+5:00 should be closer to Melbournes tzdata +10:00 or +11

Comment 1 Patsy Griffin 2016-01-12 16:04:30 UTC
Hi George,

I need more information to figure out what's going on.

Would you please provide the output of the following two commands?

date

date --utc

Also, when you look at Settings->System->Date&Time is Time Zone set to
AEDT (Sydney, Australia) ?   If not, can you please let me know what it is set to?

Thanks,
Patsy

Comment 2 George 2016-01-13 05:21:34 UTC
Hi Patsy,

See difference between Sydney and Melbourne below.  I am using system-config-date to change timezone.
I suspect Sydney should also be reporting AEDT.

Sydney
# date
Wed Jan 13 16:15:03 EST 2016
# date --utc
Wed Jan 13 21:15:12 UTC 2016

Melbourne
# date
Wed Jan 13 16:17:01 AEDT 2016
# date --utc
Wed Jan 13 05:17:05 UTC 2016

Regards,

George

Comment 3 Florian Weimer 2016-01-13 16:43:05 UTC
(In reply to George from comment #2)
> Hi Patsy,
> 
> See difference between Sydney and Melbourne below.  I am using
> system-config-date to change timezone.
> I suspect Sydney should also be reporting AEDT.
> 
> Sydney
> # date
> Wed Jan 13 16:15:03 EST 2016
> # date --utc
> Wed Jan 13 21:15:12 UTC 2016

Could you please show us the output from the command

ls -l /etc/localtime

on this system?

Comment 4 George 2016-01-13 22:47:16 UTC
Hi Florian,

See output below

#date
Thu Jan 14 09:43:18 EST 2016
# date --utc
Thu Jan 14 14:43:25 UTC 2016
#ls -l /etc/localtime
lrwxrwxrwx. 1 root root 36 Jan 13 17:43 /etc/localtime -> /usr/share/zoneinfo/Australia/Sydney

Regards,

George

Comment 5 Florian Weimer 2016-01-14 07:29:40 UTC
(In reply to George from comment #4)
> Hi Florian,
> 
> See output below
> 
> #date
> Thu Jan 14 09:43:18 EST 2016
> # date --utc
> Thu Jan 14 14:43:25 UTC 2016
> #ls -l /etc/localtime
> lrwxrwxrwx. 1 root root 36 Jan 13 17:43 /etc/localtime ->
> /usr/share/zoneinfo/Australia/Sydney

Interesting.  This looks good so far.  What's the out put of these commands?

echo $TZ
md5sum /usr/share/zoneinfo/Australia/Sydney
md5sum /usr/share/zoneinfo/US/Eastern

Could you also run

strace -s 5000 -o date.log date

and attach the date.log file?  Thanks.

Comment 6 George 2016-01-14 22:11:03 UTC
Created attachment 1114965 [details]
date.log

Comment 7 George 2016-01-14 22:14:22 UTC
$ echo $TZ

$ md5sum /usr/share/zoneinfo/Australia/Sydney
e4ca381035a34b7a852184cc0dd89baa  /usr/share/zoneinfo/Australia/Sydney
$ md5sum /usr/share/zoneinfo/US/Eastern
3cc7a113962dfceb5d89019e1009fc11  /usr/share/zoneinfo/US/Eastern

Comment 8 Florian Weimer 2016-01-14 22:53:25 UTC
(In reply to George from comment #7)

> $ md5sum /usr/share/zoneinfo/Australia/Sydney
> e4ca381035a34b7a852184cc0dd89baa  /usr/share/zoneinfo/Australia/Sydney

That's content of /usr/share/zoneinfo/US/Eastern, so something probably wrote the default, US/Eastern to /etc/localtime, thus overwriting /usr/share/zoneinfo/Australia/Sydney.  /etc/localtime as a symbolic link hasn't been supported for long, it's relatively recent on Fedora.  There might still be tools which do not deal with this correctly.

Do you have an /etc/sysconfig/clock file on this system?  Has it been upgraded from older Fedora releases, or was it a recent fresh install?

> $ md5sum /usr/share/zoneinfo/US/Eastern
> 3cc7a113962dfceb5d89019e1009fc11  /usr/share/zoneinfo/US/Eastern

This is even more odd.  Can you run sha256 on this file and preserve a copy?

You could run “dnf reinstall tzdata”, which should replace the file /usr/share/zoneinfo/Australia/Sydney with the correct version.

Comment 9 George 2016-01-15 02:21:25 UTC
This is an upgraded system not fresh install.

$ sha256sum /usr/share/zoneinfo/US/Eastern
5fa6dccc303352e1195c4348b189f3085014d8a56a1976c8e8a32bd4fedb69fd  /usr/share/zoneinfo/US/Eastern

reinstalling tzdata gives

# date
Fri Jan 15 13:19:44 AEDT 2016

Which appears to be correct.