You are not logged in.

#1 2012-08-19 09:18:27

frmi
Member
Registered: 2012-02-05
Posts: 22

[SOLVED] Gnome clock is 2 hours off hardware clock

hi, i'm not sure if this is the right place to post but here we go..

I've just installed arch on my laptop and now everything seems to work pretty well, although the clock in gnome/cinnamon is 2 hours off hwclock/localtime. Does anyone have a suggestion how to fix this? I don't seem to be able to edit it manually through the gui

Last edited by frmi (2012-08-21 15:29:45)

Offline

#2 2012-08-19 10:34:58

brebs
Member
Registered: 2007-04-03
Posts: 3,742

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

Is your timezone off from UTC by 2 hours? Set up your timezone, obviously.

I believe Arch should run "hwclock -s" at startup - haven't checked. It's what I do (different distro though).

Offline

#3 2012-08-19 11:10:20

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

i have already set the local

# ln -s /usr/share/zoneinfo/Europe/Copenhagen /etc/localtime

On my old laptop i didn't have to do hwclock -s on start up if i remember right..

Offline

#4 2012-08-19 11:38:40

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,648

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

When you did the install, did you do this step: https://wiki.archlinux.org/index.php/Be … clock_time

frmi wrote:

the clock in gnome/cinnamon is 2 hours off hwclock/localtime

Does this mean your hardware clock is set to local time?

What does

sudo hwclock

return (and is that local time)?

and what is in /etc/adjtime?

Last edited by 2ManyDogs (2012-08-19 11:40:37)

Offline

#5 2012-08-19 11:44:51

Terminator
Member
From: Belgium
Registered: 2012-05-07
Posts: 265

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

To get your system to use localtime with systemd, you need the following in /etc/adjtime:

[dean@PsyMadness etc]$ cat adjtime 
0.0 0.0 0.0
0
LOCAL

Check the systemd wiki pages if you want to know more.

Offline

#6 2012-08-19 11:45:15

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

2ManyDogs wrote:

When you did the install, did you do this step: https://wiki.archlinux.org/index.php/Be … clock_time

frmi wrote:

the clock in gnome/cinnamon is 2 hours off hwclock/localtime

Does this mean your hardware clock is set to loacal time?

What does

sudo hwclock

return (and is that local time)?

and what is in /etc/adjtime?

This just made me realise that it's the hwclock which is off localtime.
Would

# hwclock --systohc --utc

Set the clock properly or should i use localtime instead of utc?

anyway here's the output:

[fm@fm-lap ~]$ sudo hwclock
Password: 
2012-08-19T15:39:23 CEST  -0.145579 seconds
[fm@fm-lap ~]$ cat /etc/adjtime
0.000000 0 0.000000
0
UTC

Last edited by frmi (2012-08-19 11:50:01)

Offline

#7 2012-08-19 11:55:05

Terminator
Member
From: Belgium
Registered: 2012-05-07
Posts: 265

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

You should probably adapt /etc/adjtime as I said:
https://wiki.archlinux.org/index.php/Sy … clock_time

Offline

#8 2012-08-19 11:57:57

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

Okay, should i just edit i manually and should i have hwclock in my daemon list, i'm kind of confused at that point?

Offline

#9 2012-08-19 12:00:14

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,648

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

frmi wrote:
# hwclock --systohc --utc

Set the clock properly or should i use localtime instead of utc?

It should. Run it and then check /etc/adjtime again.

Offline

#10 2012-08-19 12:02:08

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

i ran it with --utc and the output is now:

0.000000 1345383973 0.000000
1345383973
UTC

though it's still 2 hours infront of my local time

Offline

#11 2012-08-19 12:05:50

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,648

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

Try rebooting.

Offline

#12 2012-08-19 12:09:51

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

I have rebooted and the hwclock is in front of local time still. The warning at https://wiki.archlinux.org/index.php/Be … clock_time about using localtime, is scaring me a bit. But might it be the way to fix it or should i do as Terminator says and just edit adjtime manually?

Offline

#13 2012-08-21 15:29:11

frmi
Member
Registered: 2012-02-05
Posts: 22

Re: [SOLVED] Gnome clock is 2 hours off hardware clock

Fixed with NTP

Offline

Board footer

Powered by FluxBB