Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
System clock gets delayed when in linux
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Wed Jul 02, 2003 6:49 pm    Post subject: System clock gets delayed when in linux Reply with quote

I don't know what happens to my linux on my laptop. Perhaps it's something with the kernel/ACPI. It seems to lose minutes and get the system's clock delayed. This happens almost always and I need it repaired. What do I have to change?
Back to top
View user's profile Send private message
green sun
Guru
Guru


Joined: 04 Nov 2002
Posts: 325
Location: Wista, MA

PostPosted: Wed Jul 02, 2003 6:53 pm    Post subject: Reply with quote

I have the same problem with a Dell Inspiron. I haven't bothered to track it down because I just loaded ntp & have it run on boot. If you connect to the Internet, this will automatically set your time. You have to configure /etc/ntp.conf to point to a ntp server on the internet, but the file has clear instructions. It can be added to start on boot with:
Code:
rc-update add ntpd default
Back to top
View user's profile Send private message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Thu Jul 03, 2003 12:07 am    Post subject: Reply with quote

Well... this is like a work-around to solve the problem... but it just does the trick for what I want so... thanks mate!
Back to top
View user's profile Send private message
kniteshade
n00b
n00b


Joined: 20 May 2003
Posts: 54

PostPosted: Thu Jul 03, 2003 1:42 am    Post subject: Reply with quote

i have the same problem with a dell inspiron too - its a known problem
basically whenever linux probes the acpi for the battery levels, the few milliseconds it takes it just 'forgets' the 'tics' that get sent while its probing the bios. The tics are sent from the bios to keep the software clock knowing what time is is - so if it doens't get them then the clock 'loses time'

If ya look for the dell-linux group on yahoo they have lots more information about it - but as of a few months ago it was an un-fixable problem.

The way i got around it is to hack up the script that synchs the hardware clock from the software one on shutdown so i lose time over the day but next day (i shut down each night) its refreshed from the hardware one

The other way is to just not run any acpi apps (battery levels etc) but thats annoying cos then ya never know when ya battery is getting low!

There might be some fixes coming soon but i think its just the whole way acpi is implemented in the kernel (cos windows doens't have the problem so it MUST be possible to fix0r)

If anyone finds anything out then post it cos i cbf looking now but would be interested is perhaps 2.4.21 or 2.5.x has it fixed

Ben
_________________
"The box said to install Windows 95, NT or better.... so in installed linux"
Back to top
View user's profile Send private message
green sun
Guru
Guru


Joined: 04 Nov 2002
Posts: 325
Location: Wista, MA

PostPosted: Thu Jul 03, 2003 12:07 pm    Post subject: Reply with quote

kniteshade wrote:
i have the same problem with a dell inspiron too - its a known problem
basically whenever linux probes the acpi for the battery levels, the few milliseconds it takes it just 'forgets' the 'tics' that get sent while its probing the bios. The tics are sent from the bios to keep the software clock knowing what time is is - so if it doens't get them then the clock 'loses time'

If ya look for the dell-linux group on yahoo they have lots more information about it - but as of a few months ago it was an un-fixable problem.

The way i got around it is to hack up the script that synchs the hardware clock from the software one on shutdown so i lose time over the day but next day (i shut down each night) its refreshed from the hardware one

The other way is to just not run any acpi apps (battery levels etc) but thats annoying cos then ya never know when ya battery is getting low!

There might be some fixes coming soon but i think its just the whole way acpi is implemented in the kernel (cos windows doens't have the problem so it MUST be possible to fix0r)

If anyone finds anything out then post it cos i cbf looking now but would be interested is perhaps 2.4.21 or 2.5.x has it fixed

Ben


knightshade
thanks for the info... like I said, I never looked into it too deeply. I use ntp to fix the clock (except on my home PC, which because my ISP blocks the ntp port?!?) But its not too annoying anyways... besides, I could probably run an ntp server at work & connect over a different port should I *really* need to do so at home...
Back to top
View user's profile Send private message
lannie
n00b
n00b


Joined: 22 May 2002
Posts: 33

PostPosted: Thu Jul 03, 2003 3:53 pm    Post subject: Reply with quote

Hi !

I have one of those troubled Dell Inspirons (Inspiron 4000). From my past experiences the gentoo-sources give the most time lag

I use the vanilla-sources and that fixes the time lag. However I don't use ACPI in the kernel... i use APM :D

Other from that, I don't know why there is the time lag... I remembered that when i used the pre-empt patches for the kernels... it always stuffed up the time on the machine.

well hope this helps
-Lan
Back to top
View user's profile Send private message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Thu Jul 03, 2003 4:15 pm    Post subject: Reply with quote

After all this, what I say is we have to wait for a kernel with a completely working ACPI and, meanwhile, have a work-around on the problem. Thanks to all for your answers.
Back to top
View user's profile Send private message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Thu Jul 03, 2003 4:15 pm    Post subject: Reply with quote

lannie wrote:
Hi !

I have one of those troubled Dell Inspirons (Inspiron 4000). From my past experiences the gentoo-sources give the most time lag

I use the vanilla-sources and that fixes the time lag. However I don't use ACPI in the kernel... i use APM :D

Other from that, I don't know why there is the time lag... I remembered that when i used the pre-empt patches for the kernels... it always stuffed up the time on the machine.

well hope this helps
-Lan


What happens in my laptop it's that it's completely new and has no APM, only ACPI... APM is considered obsolete by manufacturers right now.
Back to top
View user's profile Send private message
lannie
n00b
n00b


Joined: 22 May 2002
Posts: 33

PostPosted: Thu Jul 03, 2003 4:54 pm    Post subject: Reply with quote

Quote:
APM is considered obsolete by manufacturers right now.


after all dude, my laptop is old after all :D

...well you could try ACPI without the pre-empt patches... see how that goes...

reason being.. when i tried the pre-empt patches on the laptop... it will screw up the time no matter what... this was true on the redhat 9 and mandrake 9.1 kernels... (when i put the computer into suspend mode)

well .. good luck :)

-Lan

B.T.W - Does anyone know if the development kernels will fix these problems?
Back to top
View user's profile Send private message
Deathwing00
Bodhisattva
Bodhisattva


Joined: 13 Jun 2003
Posts: 4087
Location: Dresden, Germany

PostPosted: Thu Jul 03, 2003 10:46 pm    Post subject: Reply with quote

lannie wrote:
Quote:
APM is considered obsolete by manufacturers right now.


after all dude, my laptop is old after all :D

...well you could try ACPI without the pre-empt patches... see how that goes...

reason being.. when i tried the pre-empt patches on the laptop... it will screw up the time no matter what... this was true on the redhat 9 and mandrake 9.1 kernels... (when i put the computer into suspend mode)

well .. good luck :)

-Lan

B.T.W - Does anyone know if the development kernels will fix these problems?


I have ACPI enabled and everything works... I don't mind having to sync clock, even manually, I just wanted to know why and how... I can wait for a new kernel :P
Back to top
View user's profile Send private message
snowpatch
n00b
n00b


Joined: 09 Mar 2003
Posts: 38
Location: Philadelphia

PostPosted: Wed Aug 13, 2003 2:19 am    Post subject: re: time lag on inspiron with apm Reply with quote

This may not help with an ACPI only laptop, but my Inspiron 4150 (which can use either) is using APM, and I came across a post in the linux-dell-laptops yahoo forum:

http://groups.yahoo.com/group/linux-dell-laptops/message/19594

Apparently upgrading to BIOS A06 has helped a few people with clock-drift and suspend/resume problems.
Back to top
View user's profile Send private message
BitJam
Advocate
Advocate


Joined: 12 Aug 2003
Posts: 2508
Location: Silver City, NM

PostPosted: Wed Aug 13, 2003 4:41 am    Post subject: Reply with quote

My clock is fixed on a Dell Inspiron 8200

I installed the lastest BIOS, and use the 2.4.22_pre2-gss kernel with APM enabled.

I stopped running ntpd weeks ago. I just checked and I'm within 4 seconds of nist time.
Back to top
View user's profile Send private message
swimgeek
Tux's lil' helper
Tux's lil' helper


Joined: 09 May 2003
Posts: 124
Location: Minneapolis, MN, USA

PostPosted: Sun Aug 17, 2003 3:26 pm    Post subject: Still having time problems Reply with quote

Hi,
I have an inspiron 4150 and I upgraded to A06 today. After synching the BIOS clock I rebooted, and checked the BIOS clock and the time seemed to be fine. However as soon as I booted into Linux (without network, so that ntpd didn't startup) the time was offset by about 30 minutes. I'm going to try with the vanilla 2.4.21 and see if it makes difference, but my past experience has showed it doesn't. Should I try a premptible kernel? Will that affect anything else?

thanks!
Back to top
View user's profile Send private message
BitJam
Advocate
Advocate


Joined: 12 Aug 2003
Posts: 2508
Location: Silver City, NM

PostPosted: Sun Aug 17, 2003 4:36 pm    Post subject: Reply with quote

I've wondered about that. You could always give it a try. I've got my clocking working just fine now on an 8200 and my kernel is configured with preemptible on.
Back to top
View user's profile Send private message
kronon
Apprentice
Apprentice


Joined: 11 Aug 2003
Posts: 212
Location: NL

PostPosted: Sun Aug 17, 2003 4:40 pm    Post subject: Reply with quote

since some time my laptop has the same problem but probably wors. I don't lose milisecond I lose minutes. Today my clock is 5 minutes behind. I don't know how this can be but I hope it get's solved soon.
Back to top
View user's profile Send private message
swimgeek
Tux's lil' helper
Tux's lil' helper


Joined: 09 May 2003
Posts: 124
Location: Minneapolis, MN, USA

PostPosted: Sun Aug 17, 2003 5:18 pm    Post subject: possible solution? Reply with quote

I removed /etc/adjtime and rebooted (the system time from ntpd was written to hwclock during shutdown) without network (so that ntpd wouldn't start) and time seemed to be fine!! I will follow up on this approach in the days to come and see if it continues to work :)
Back to top
View user's profile Send private message
Yukimura
Apprentice
Apprentice


Joined: 25 Aug 2006
Posts: 163
Location: Slovenia

PostPosted: Thu Jan 11, 2007 6:36 pm    Post subject: Time issues Reply with quote

Hello everyone! :)

I'm having problems with time on my gentoo desktop machine. I don't know what the cause might be but for some strange reason when I boot my system I see my clock at least 20min behind the real clock, but it usually happens that my clock on pc is late for 7 hours.

Any idea what can I do?

Kind regards. ;)
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Thu Jan 11, 2007 7:54 pm    Post subject: Reply with quote

merged above post here.
You should find some ideas here.
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
Yukimura
Apprentice
Apprentice


Joined: 25 Aug 2006
Posts: 163
Location: Slovenia

PostPosted: Wed Feb 28, 2007 8:59 am    Post subject: Reply with quote

Hello!

I found the "solution" for this one. I edited /etc/conf.d/clock and changed the next line:

Quote:
# If you want to set the Hardware Clock to the current System Time
# during shutdown, then say "yes" here.

CLOCK_SYSTOHC="yes"


It works for me! There are some minimal delays but that's like a minute or so.

Kind regards!:)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware 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