how to change the Universal Time

Asked by Laurent

I have installed ubuntu 6.0.6. But I found the universal time is not correct.
Here is the system time I got from system:

Your default time zone is set to 'Asia/Chongqing'.
Local time is now: Wed Aug 22 20:50:15 CST 2007.
Universal Time is now: Wed Aug 22 12:50:15 UTC 2007.

The local time should be Wed Aug 22 12:50:15, the universal time should be Wed Aug 22 4:50:15.
How can I configure the system time correctly?
thanks.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Laurent
Solved:
Last query:
Last reply:
Revision history for this message
Artem Popov (artfwo) said :
#1

Hi, Laurent!

You should try setting your system time with any of these commands:
date -s 12:50:15
OR
hwclock --set --date='08/22/07 12:50:15' --localtime

If you also have Windows on your machine, then please check this forum thread on how to sync the clock between the 2 OSes:
http://ubuntuforums.org/showthread.php?p=2616096

Hope this helps :)

Revision history for this message
Laurent (aug-flower) said :
#2

Hi, Артём Попов:
  Thanks for your answer. I have solved the problem by the method below. It is derived from https://answers.launchpad.net/ubuntu/+question/2939
  I think we solved the problem with different way for the same reason.

Ubuntu assumes that your hardware clock is set to UTC (Universal Time Coordinated).
I set the hardware clock to use the local time by modifying "/etc/default/rcS".

----
# Set UTC=yes if your system clock is set to UTC (GMT), and UTC=no if not.
UTC=yes
---

Br/

Revision history for this message
Artem Popov (artfwo) said :
#3

Wow, this is even better solution definetly! :)