Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Gnome] Unable to set the right time on Clock 2.32.1
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Tue Apr 17, 2012 1:56 pm    Post subject: [Gnome] Unable to set the right time on Clock 2.32.1 Reply with quote

Hi,

when I installed gnome, I realized that the time was wrong. So I corrected it.

But the next time I started my computer, the time was wrong again.

So I looked for a solution on the internet and I found that the Bios was guilty.

So I set the right time on the Bios Clock and it worked.

Well, until a restart my computer... the bios system clock was back to the wrong time again.

What is it due to ? And how could I fix it ?

Thanks
Back to top
View user's profile Send private message
genblood
Tux's lil' helper
Tux's lil' helper


Joined: 03 Dec 2003
Posts: 133
Location: New Hampshire

PostPosted: Tue Apr 17, 2012 11:01 pm    Post subject: Reply with quote

Check your hwclock file. The location is /etc/conf.d/ directory.

Set the clock to local and it should fix your issue.

Go to the Gentoo Handbook, Code Listing 3.4: Opening /etc/conf.d/hwclock
You can get more info their on the subject.
_________________
General Blood ..

Gentoo 2008.0 AMD Phemon X4 9850+ 8GB DDR2 1066
MSI K9A2 Platium Mother Board ATI 4830 PCI-e 512MB
1 Blu-Ray Drive
4 sata WD 500 GB drive
Back to top
View user's profile Send private message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Tue Apr 17, 2012 11:11 pm    Post subject: Reply with quote

Already done all of that.

The only things that could be wrong is that /etc/localtime is unreadable (I thought that was because it is a binary file ?)

Code:

TZif2

     �
      �`P��Gx���,p���p��H����p��*��`����
                                         ��.��zL��5���^#p�%5��'���X&p�}���4p��_���P���A�������#���Op�����k��p"p�r�p�Pp�I/��/�p�2Lp��p���p���p��`���������������_p���������xl��h]��XN��?p�80��:���X�p��   ��l'���K�����C��4�O�������r�N@�
                                                                             �9
�c���E�t6�d'�T�MD3��#��������������������������|� lr!\c"LT#<E$,6%'&
                                                                                                      'C�'�4�(�%�)��*��+���,���-���.���/t��0d��1]�2r�3=�4R�5�62x6�8��8�a9�v�:�C;�X�<�_�=�:�>�A�?��@f#�A�9BF�CdD%��EC�F��G#�G��I�I��J��K��L���MN���OnnP���QW��Rle�S7l�TLG�UN�V,)�V�0�XFX��Y�(Z���[�
\�]��^�_��`_�a}��b?�c]��d�e=����g��g���h�r�i�y�j�T�k�[�l�qm�=�n�Soh�p�5qQ<rfs1tE�uv/�v��x��x��y���z��{���|���}���~y���   

-[MANY BLANK LINES HERE ]-

����k�J������`P������Gx�������,p�������p������H��������p������*������`��������
                                                                               ������.������zL������5�������^#p�����%5������'�������X&p�����}�������4p������_�������P�������A���������������#�������Op�������������k������p"p�����r�p�����Pp�����I/������/�p�����2Lp������p�������p�������p������`�������������������������������_p���������������������xl������h]������XN������?p�����80������:�������X�p������   ������l'�������K�������������C������4�����O���������������r�����N@�
                                                                                                                                                 �9
�c���E�t6�d'�T�MD3��#��������������������������|� lr!\c"LT#<E$,6%'&                                             ��
                                                                                                      'C�'�4�(�%�)��*��+���,���-���.���/t��0d��1]�2r�3=�4R�5�62x6�8��8�a9�v�:�C;�X�<�_�=�:�>�A�?��@f#�A�9BF�CdD%��EC�F��G#�G��I�I��J��K��L���MN���OnnP���QW��Rle�S7l�TLG�UN�V,)�V�0�XFX��Y�(Z���[�
\�]��^�_��`_�a}��b?�c]��d�e=����g��g���h�r�i�y�j�T�k�[�l�qm�=�n�Soh�p�5qQ<rfs1tE�uv/�v��x��x��y���z��{���|���}���~y���      

-[MANY BLANK LINES HERE ]-

    LMTPMTWESTWETCETCESTWEMT
CET-1CEST,M3.5.0,M10.5.0/3
Back to top
View user's profile Send private message
genblood
Tux's lil' helper
Tux's lil' helper


Joined: 03 Dec 2003
Posts: 133
Location: New Hampshire

PostPosted: Tue Apr 17, 2012 11:48 pm    Post subject: Reply with quote

Where you able to set your tome zone to CET?

Code Listing 1.1: Setting the timezone information

# ls /usr/share/zoneinfo (displays timezone info )

# cp /usr/share/zoneinfo/CET /etc/localtime ( your time zone info)

# echo "CET" > /etc/timezone ( sets your time)

If you think you have some damaged files .. emerge gentoolkit and run
"revdep-rebuild" .

I hope this helps you out.
_________________
General Blood ..

Gentoo 2008.0 AMD Phemon X4 9850+ 8GB DDR2 1066
MSI K9A2 Platium Mother Board ATI 4830 PCI-e 512MB
1 Blu-Ray Drive
4 sata WD 500 GB drive
Back to top
View user's profile Send private message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Wed Apr 18, 2012 1:02 am    Post subject: Reply with quote

My timezone is set to Europe/Paris.

All files in /usr/share/zoneinfo are unreadable.

I've already done revdep-rebuild, fruitlessly. :?
Back to top
View user's profile Send private message
genblood
Tux's lil' helper
Tux's lil' helper


Joined: 03 Dec 2003
Posts: 133
Location: New Hampshire

PostPosted: Wed Apr 18, 2012 2:24 am    Post subject: Reply with quote

You could try re-emerging sys-libs/timezone-data.
_________________
General Blood ..

Gentoo 2008.0 AMD Phemon X4 9850+ 8GB DDR2 1066
MSI K9A2 Platium Mother Board ATI 4830 PCI-e 512MB
1 Blu-Ray Drive
4 sata WD 500 GB drive
Back to top
View user's profile Send private message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Wed Apr 18, 2012 9:32 am    Post subject: Reply with quote

I reemerged it but the files are still unreadable. I thinks it's normal (man tzfile).

However I'm on a track. Each time I reset the system clock so that it displays the right time, I also run "hwclock -w" so that the hardware clock also has the right time.

I noticed that if I don't do that, the system clock keeps the right time.

So how do I get hwclock to the same time as the system clock ?
Back to top
View user's profile Send private message
BillWho
Veteran
Veteran


Joined: 03 Mar 2012
Posts: 1600
Location: US

PostPosted: Wed Apr 18, 2012 1:27 pm    Post subject: Reply with quote

apinsard,

hwclock --hctosys will reset the system clock from hardware clock

hwclock --systohc will reset the hardware clock from system clock

Good luck :wink:
_________________
Good luck :wink:

Since installing gentoo, my life has become one long emerge :)
Back to top
View user's profile Send private message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Wed Apr 18, 2012 4:10 pm    Post subject: Reply with quote

Yeah that's what i did, -w is equivalent to --systohc. It works until i reboot my computer.
Back to top
View user's profile Send private message
BillWho
Veteran
Veteran


Joined: 03 Mar 2012
Posts: 1600
Location: US

PostPosted: Wed Apr 18, 2012 4:39 pm    Post subject: Reply with quote

apinsard,

If this helps I have clock="local" and clock_args="" set in /etc/conf.d/hwclock - the others are commented

#clock_hctosys="NO"

#clock_systohc="YES"

/etc/localtime is symlinked /etc/localtime -> /usr/share/zoneinfo/America/New_York and

Code:
root@gentoo-gateway script # rc-update|grep hwclock
              hwclock | boot

I haven't had any problems with the time :?
_________________
Good luck :wink:

Since installing gentoo, my life has become one long emerge :)
Back to top
View user's profile Send private message
apinsard
n00b
n00b


Joined: 24 Mar 2012
Posts: 74
Location: France

PostPosted: Wed Apr 18, 2012 6:14 pm    Post subject: Reply with quote

that's exactly what I have too... :?
Back to top
View user's profile Send private message
genblood
Tux's lil' helper
Tux's lil' helper


Joined: 03 Dec 2003
Posts: 133
Location: New Hampshire

PostPosted: Wed Apr 18, 2012 11:16 pm    Post subject: Reply with quote

That's strange ... here is what's in my hwclock file

Quote:

# cat /etc/conf.d/hwclock

# Set CLOCK to "UTC" if your Hardware Clock is set to UTC (also known as
# Greenwich Mean Time). If that clock is set to the local time, then
# set CLOCK to "local". Note that if you dual boot with Windows, then
# you should set it to "local".
clock="local"

# If you want the hwclock script to set the system time (software clock)
# to match the current hardware clock during bootup, leave this
# commented out.
# However, you can set this to "NO" ifyou are running a modern kernel
# with CONFIG_RTC_HCTOSYS set to y and your hardware clock set to UTC.
#clock_hctosys="YES"

# If you do not want to set the hardware clock to the current system
# time (software clock) during shutdown, set this to no.
#clock_systohc="YES"

# If you wish to pass any other arguments to hwclock during bootup,
# you may do so here. Alpha users may wish to use --arc or --srm here.
clock_args=""


The only thing I might have done extra was select real time clock in the kernel.
_________________
General Blood ..

Gentoo 2008.0 AMD Phemon X4 9850+ 8GB DDR2 1066
MSI K9A2 Platium Mother Board ATI 4830 PCI-e 512MB
1 Blu-Ray Drive
4 sata WD 500 GB drive
Back to top
View user's profile Send private message
BillWho
Veteran
Veteran


Joined: 03 Mar 2012
Posts: 1600
Location: US

PostPosted: Thu Apr 19, 2012 1:52 am    Post subject: Reply with quote

apinsard,

Do you have ntp-client and ntpd set in the default runlevel :?:
Code:
root@gentoo-gateway modules # rc-update|grep ntp
           ntp-client |      default                 
                 ntpd |      default                 

This is the only other thing I can think of :?
_________________
Good luck :wink:

Since installing gentoo, my life has become one long emerge :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum