OESF Portables Forum

General Forums => General Discussion => Topic started by: waalkman on December 12, 2004, 03:17:43 am

Title: System Time/date Problems
Post by: waalkman on December 12, 2004, 03:17:43 am
Guys, I keep getting a "The system date doesn't seem to be valid" when I reboot (which is happening fairly often because of package manager lockups).

Usually the time isn't anywhere near accurate so I don't bother with it. But the system date messages are getting annoying

Currently I'm using OZ 3.5.2 on a C860, but I have had timekeeping problems with every ROM that I've tried. Not to mention my 5500.

Is there something wrong with how the Z keeps time?


Thanks.
Title: System Time/date Problems
Post by: Bundabrg on December 13, 2004, 01:36:59 am
Yes and no.

The C Series do not have a hardware clock. So each time you reset it will reset it to the beginning of the epoch.

However, there is a 'kinda' fix. Install the 'slutils' package. This creates a file 'sltime' in /usr/bin

Now each time you run 'sltime -set', it will take the current time and store it on the Z.
Each time you run 'sltime' (without any parameters) it will restore the saved time.

So it may be useful to have it 'set' the time when the unit is shut down, or each time it suspends, or even via cron every 30 minutes, and have it 'restore' the time on a reboot.

I'll probably create an ipk with this all auto one day soon.

 - Bundabrg
Title: System Time/date Problems
Post by: Bundabrg on December 13, 2004, 01:39:10 am
Actually you shouldn't have time problems with pdaXrom. It already uses sltime by default. My only change with it was to add a cronjob that runs sltime -set every hour. When I work out how to do it on 'suspend'/'resume' then that would be a useful place.

 - Bundabrg
Title: System Time/date Problems
Post by: lpotter on December 13, 2004, 04:10:26 pm
Here's a bad hack of a init script that saves time on shutdown and restores it on bootup.
Title: System Time/date Problems
Post by: waalkman on January 12, 2005, 01:46:34 am
Thanks guys!

Sorry it took so long for me to get back to you, I was on vacation (sabbatical more like it).

Thanks for the package, I've already snagged it.

Surprisingly enough, cacko 1.22 does a good job of keeping time so I don't need it at the moment. I'm sure it will come in handy the next time I switch ROMs

Thanks again


John
Title: System Time/date Problems
Post by: nianderson on January 19, 2005, 06:58:35 pm
Can we get that dateinit reattached after the forum move? or is it working for everyone but me?

thanks