LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Clock Problem (https://www.linuxquestions.org/questions/debian-26/clock-problem-387198/)

Nick69 11-28-2005 04:33 AM

Clock Problem
 
Hi all,

I recently installed a Debian Sarge on a IBM ThinkCentre (Pentium 4 HT).
After having compiling the last kernel (2.6.14.2) with HT module, resolving some latence problems, I've got a strange behavior about the clock system.

My hard one (BIOS) still correct, but the date of the system goes backwards after a random (I think) time.

Here is the result of the date command each "real world" second :

Code:

everest:~# date
dim nov 27 02:24:37 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:37 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:37 CET 2005
everest:~# date
dim nov 27 02:24:37 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:38 CET 2005
everest:~# date
dim nov 27 02:24:39 CET 2005

But some times this works well...:confused:

I already change the battery on my motherboard.

Any ideas ?

macondo 11-29-2005 11:31 AM

# apt-get install ntpdate

haertig 11-29-2005 12:13 PM

I can't say why you're seeing the drift in time as reported by the "date" command. Maybe that's just the way it is. I haven't run the date command multiple times per second to see if any of my systems exhibit this drift.

FYI, the "date" command reports the "system clock time". This is seperate from the "real time clock" (a.k.a. "BIOS clock", "hardware clock", "CMOS clock") which is reported by the "hwclock" command. You must be root to run hwclock. Invoke it like "hwclock --show" to read your hardware clock.

When your system boots, the hardware clock is read and the result is used to set the system clock. From then on out the hardware clock is not used. When you shutdown, the system clock data is written back to the hardware clock on many systems.

Other programs like "rdate", "ntpd", "ntpdate", etc. can be used to set your system clock using an external source as reference.

Nick69 11-30-2005 03:36 AM

Thanks for your responses.

I knew the "ntpdate" programs and other, but the problem was that my system went wrong during my system was up (no reboot at all).

Anyway, I resolved the problem removing some all modules in kernel about the clock. I know it is the easiest way, but it works...

Thanks again,

dukezero 10-25-2006 01:42 PM

same problem
 
hey! Im just having the same problem with another IBM ThinCentre (w/ Pentium4 processor) and Linux kernel 2.16.6.1:

The system clock seems to be crazy: Most of the time it is running ok but eventually it slows down, and other times even jumping backwards several seconds. Seems to be a kernel issue

You said you solved the problem removing some modules from the kernel. Can you tell me which ones?

I am running these daemons in the server: postgresql, httpd(apache), svscan(daemonstool), acpid. Could these programs cause the clock behavior?

thanks a lot,


DukeZer0

Nick69 10-26-2006 02:30 AM

Hey Dukezero!

Well I solved my problem a long time ago, and I didn't notice the fix procedure... But I remember that the solution was in the kernel configuration, not about software.
Have a look at :

- Processor type and features > HPET Timer Support
> Symmetric multi-processing support [2 cpu]
> SMT (Hyperthreading) scheduler support
> No Forced Preemption (Server)
> Timer frequency (100Hz)
- No Power management options at all.

Hope it will help you.

Cheers,
Nick

dukezero 10-26-2006 05:45 PM

100Hz?
 
hey nick! lots of thanks for your reply
I am rebuilding a kernel now. hope it works

the time freq should be 100Hz?

dukezero

Nick69 10-27-2006 02:25 AM

Well that what I use... ;)

jptxs 11-07-2006 08:01 PM

crazy clock solution?
 
Quote:

Originally Posted by dukezero
hey! Im just having the same problem with another IBM ThinCentre (w/ Pentium4 processor) and Linux kernel 2.16.6.1:

The system clock seems to be crazy: Most of the time it is running ok but eventually it slows down, and other times even jumping backwards several seconds. Seems to be a kernel issue

You said you solved the problem removing some modules from the kernel. Can you tell me which ones?

I am running these daemons in the server: postgresql, httpd(apache), svscan(daemonstool), acpid. Could these programs cause the clock behavior?

thanks a lot,


DukeZer0

Did you figure this one out? I'm having almost the exact same issue...

anseljh 11-08-2006 07:58 PM

Me too!
 
Quote:

Originally Posted by jptxs
Did you figure this one out? I'm having almost the exact same issue...

I'm having the same problem on an IBM NetVista Pentium 4 w/ Ubuntu (Dapper/Server). Has anyone solved this? If so, what did you do?

:confused:

dukezero 11-09-2006 12:24 PM

Solved!
 
The problem is solved. Thanks a lot Nick!

This is what I did: I rebuild the kernel, making the following changes in the configuration:

Symmetric multi-processing support -> Disabled
SMT (Hyperthreading) scheduler support-> Disabled
Preemption-> No Forced Preemption (Server)
Timer Frequency->100Hz

The kernel was the latest 2.6.? version but this procedure should work with other versions.
I did not remove the ACPI power management options and it worked OK.

This may be a serious kernel issue that the developers are maybe ignoring!

DukeZero.


All times are GMT -5. The time now is 02:05 AM.