can't change timezone on Fedora Core

I've tried:

ln -sf /usr/share/zoneinfo/Europe/London /etc/localtime

I've set ZONE="Europe/London" in /etc/sysconfig/clock

I've set my TZ environment variable to Europe/London

And still, date returns EDT for the timezone.

Does anyone have any other ideas for setting the timezone?

6 Replies

Looking in /usr/share/zoneinfo, it seems some files work, and some don't - meaning date resorts to EDT.

/usr/share/zoneinfo/GB doesn't work, but /usr/share/zoneinfo/posix/GB does - providing British Summer Time.

I'm not sure why this is - but my problem seems to be solved.

Thanks

I think you need to copy the zoneinfo file into /etc/localtime rather than symlink it. You might also need to reboot.

There is a GUI tool system-config-time that can do the work for you. Running GUI programs on a Linode is beyond the scope of this message, though… you could use ssh -X (not into LISH!) or a VNC desktop.

FWIW, I prefer to run servers on UTC.

@rjp:

I think you need to copy the zoneinfo file into /etc/localtime rather than symlink it. You might also need to reboot.

Copying is better because if the target of the symlink isn't ready very early in the boot process (eg if /usr is on a different filesystem from root) then the system will default to as if it had no timezone file.

Rebooting is a good idea because any already running process that's referenced localtime (think, for example, syslog) will retain the old data.

I experienced this problem too:

/usr/share/zoneinfo/America/New_York

did not work for me, but

this:

/usr/share/zoneinfo/posix/America/New_York

worked fine

Shouldn't this be handled by the distribution rather than by copying files and symlinks around? If your distro does handle it and you're going around that, you're looking for trouble.

On debian it's dpkg-reconfigure tzdata
Not sure about Fedora.

I used Centos. There is a gui tool, but there is no problem with doing it manually on redhat distros.

distro tools aside, copying a file to /etc/localtime is the way to do it furthest down the "stack". If that doesn't work, there is a problem somewhere

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct