Can't adjust time

106 views
Skip to first unread message

Stealth

unread,
Dec 7, 2012, 5:06:31 AM12/7/12
to al...@googlegroups.com
Hello,

I have a problem to adjust time (hour only)
My timezone is correct

more /etc/timezone
Europe/Paris

But the hour is false
date
Fri Dec  7 11:58:01 CEST 2012 ->  10:58 is the correct hour

When I'm try to adjust manually

# date -s "11:00"
Fri Dec  7 11:00:00 CEST 2012

Ok good, but

# /etc/init.d/S43ntp restart
Restarting ntpd:
Stopping ntpd: OK.
ntpd: Getting initial time via ntp: OK.
Starting ntpd: OK.
# date
Fri Dec  7 12:01:36 CEST 2012

:-(




Joao Cardoso

unread,
Dec 7, 2012, 10:12:24 AM12/7/12
to al...@googlegroups.com


On Friday, December 7, 2012 10:06:31 AM UTC, Stealth wrote:
Hello,

I have a problem to adjust time (hour only)
My timezone is correct

more /etc/timezone
Europe/Paris

That is used only for display, it is merely decorative.
The real stuff is in /etc/TZ

Mine is 'WET0WEST,M3.5.0/1,M10.5.0' , what is yours?

TZ  names your time zone in winter/summer time, the hourly displacement from GMT and when the winter/summer time changes (DST).
If yours is wrong, you can fix it in Setup->Time, check "Fix DST", set when DST starts/ends and send me the correct TZ, so I can fixit for good.


But the hour is false
date
Fri Dec  7 11:58:01 CEST 2012 ->  10:58 is the correct hour

When I'm try to adjust manually

# date -s "11:00"
Fri Dec  7 11:00:00 CEST 2012

Ok good, but

# /etc/init.d/S43ntp restart

You could as well just use 'rcntp restart', it is a shortcut (rc<service_name> [start|stop|restart|status|enable|disable|...] )
 
Restarting ntpd:
Stopping ntpd: OK.
ntpd: Getting initial time via ntp: OK.
Starting ntpd: OK.

what timeserver are you using?

Stealth

unread,
Dec 8, 2012, 1:02:51 PM12/8/12
to al...@googlegroups.com



Hello,

I have a problem to adjust time (hour only)
My timezone is correct

more /etc/timezone
Europe/Paris

That is used only for display, it is merely decorative.
The real stuff is in /etc/TZ

Mine is 'WET0WEST,M3.5.0/1,M10.5.0' , what is yours?


No file

 

TZ  names your time zone in winter/summer time, the hourly displacement from GMT and when the winter/summer time changes (DST).
If yours is wrong, you can fix it in Setup->Time, check "Fix DST", set when DST starts/ends and send me the correct TZ, so I can fixit for good.

Correct TZ for France

CET-1CEST,M3.5.0/2:0,M10.5.0/3:0

 


what timeserver are you using?
It's good now, thank again

Just a little thing , the web interface said -> the following files have changed ... /etc/ntpd.drift, but it change often and I guess it's a normal behavior 

Joao Cardoso

unread,
Dec 11, 2012, 11:11:38 AM12/11/12
to al...@googlegroups.com


On Saturday, December 8, 2012 6:02:51 PM UTC, Stealth wrote:



Hello,

I have a problem to adjust time (hour only)
My timezone is correct

more /etc/timezone
Europe/Paris

That is used only for display, it is merely decorative.
The real stuff is in /etc/TZ

Mine is 'WET0WEST,M3.5.0/1,M10.5.0' , what is yours?


No file

This shouldn't happens. Have you done something unusual?


TZ  names your time zone in winter/summer time, the hourly displacement from GMT and when the winter/summer time changes (DST).
If yours is wrong, you can fix it in Setup->Time, check "Fix DST", set when DST starts/ends and send me the correct TZ, so I can fixit for good.

Correct TZ for France

CET-1CEST,M3.5.0/2:0,M10.5.0/3:0


Thanks, it is in accordance with the shipped value, CET-1CEST,M3.5.0,M10.5.0/3, which start time defaults to 2:00:

"The time fields specify when, in the local time currently in effect, the change to the other time occurs. If omitted, the default is 02:00:00." http://www.gnu.org/software/libc/manual/html_node/TZ-Variable.html


what timeserver are you using?

You could as well use fr.pool.ntp.org
 

 
It's good now, thank again

Just a little thing , the web interface said -> the following files have changed ... /etc/ntpd.drift, but it change often and I guess it's a normal behavior 

You are using 'ntp' as a daemon in Services->network->ntp->Configure.
Nothing wrong with that, just wasting some resources and keeping the time constantly right to the millisecond.
The  /etc/ntpd.drift file is maintained by the ntp server, and represents how the box clock drifts against time, generally related to box temperature changes. It is normal, but the value changes, so a warning appears.
You can disregard the warning, as after a few days the changes are minimal. That has only implications on how long will the ntpd server will take to become in sync with the main ntpd servers after a reboot.

The alternative, adjusting the clock only once every day at 6 in the morning will conserve resources, and will as well adjust the box clock drift.
The changes are keep in /etc/adjtime.conf, and you will get an warning when that file changes. As with ntpd.drift, after a few days the value changes only by small amounts.

João

 
Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
0 new messages