EasyOS won't save daylight saving time (Solved)

Moderator: BarryK

Post Reply
stevie pup
Posts: 209
Joined: Mon May 10, 2021 7:40 pm
Location: Derbyshire, UK
Has thanked: 14 times
Been thanked: 53 times

EasyOS won't save daylight saving time (Solved)

Post by stevie pup »

I decided to give EasyOS another try out a few days ago. I first tried it some time last year, but unfortunately it was a dismal failure. Can't remember now what the issues were but there were quite a few of them. Looking back some of it could well have been a hardware problem as the laptop I was using at the time died completely a couple of months later.

Pleased to say almost everything appears to be ok with my latest attempt except for one small niggle. It won't save the clock time! Every time I boot it up the clock is an hour out, as though it isn't recognising British Summer Time. I always "save session", and any other settings I make are always saved, just not the time. So I reset it, and next time I boot it's back to being an hour out.

Perfectly possible that I'm missing something, or doing something daft. Anyone got any ideas and/or suggestions?

Thanks

Last edited by stevie pup on Fri Apr 14, 2023 10:13 am, edited 1 time in total.
pp4mnklinux
Posts: 846
Joined: Wed Aug 19, 2020 5:43 pm
Has thanked: 516 times
Been thanked: 232 times

EasyOS Clock

Post by pp4mnklinux »

It's only an idea, because I never worked with EASYos (only to choose the logo viewtopic.php?p=83069#p83069 ) but it continues happening when you chose the option "update clock everytime you connect to the internet"??

In puppy you can choose this option when first boot.

User avatar
Keef
Posts: 250
Joined: Tue Dec 03, 2019 8:05 pm
Has thanked: 3 times
Been thanked: 67 times

Re: EasyOS won't save daylight saving time

Post by Keef »

Use Qsync from the Date and Time Setup. Find it either in the main menu under Setup, or click on the time in the taskbar.

FeodorF
Posts: 161
Joined: Tue Jul 14, 2020 7:52 pm
Has thanked: 8 times
Been thanked: 24 times

Re: EasyOS won't save daylight saving time

Post by FeodorF »

@stevie pup

Adding this script to /root/Startup will fix your problem.
(Simply remove the fake .gz before use.)

set-UTC-time-for-my-country.gz
(83 Bytes) Downloaded 30 times

If you run Menu > Setup > Quick Setup > Europe/London plus UTC option everything will be saved and read after the reboot correctly now.

btw: my RTC is set to UTC + 0 to do the above

stevie pup
Posts: 209
Joined: Mon May 10, 2021 7:40 pm
Location: Derbyshire, UK
Has thanked: 14 times
Been thanked: 53 times

Re: EasyOS won't save daylight saving time

Post by stevie pup »

Thank you all for your suggestions. But would you believe it, I've just booted Easy again and this time it's defaulted to correct time, yet I haven't tried anything or changed any settings. Something very weird going on here. So I will leave it alone for now and see what happens next time I boot it.

User avatar
BarryK
Posts: 2273
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 93 times
Been thanked: 564 times

Re: EasyOS won't save daylight saving time

Post by BarryK »

stevie pup wrote: Tue Apr 11, 2023 10:23 am

Thank you all for your suggestions. But would you believe it, I've just booted Easy again and this time it's defaulted to correct time, yet I haven't tried anything or changed any settings. Something very weird going on here. So I will leave it alone for now and see what happens next time I boot it.

Curious.

Yes, as Keef posted, Setup -> Date and Time Setup and choose Qsync
Then it will set time from the Internet.

User avatar
BarryK
Posts: 2273
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 93 times
Been thanked: 564 times

Re: EasyOS won't save daylight saving time (Solved; fixed itself.)

Post by BarryK »

The 'init' script in the initrd is supposed to set the system time when reboot. Here is the relevant code:

Code: Select all

if [ -e /sys/class/rtc/rtc0 ];then
 if [ -s /mnt/${WKG_DEV}/${WKG_DIR}.session/etc/clock ];then
. /mnt/${WKG_DEV}/${WKG_DIR}.session/etc/clock #has HWCLOCKTIME=localtime or utc
  #20230414 not sure if busybox hwclock accepts "--localtime" use "-l"...
  case "$HWCLOCKTIME" in
   localtime) hwclock -s -l -f /dev/rtc0; CLKflg=$? ;;
   utc)       hwclock -s -u -f /dev/rtc0; CLKflg=$? ;;
  esac
 else #first bootup, assume hw clock is localtime...
  hwclock -s -l -f /dev/rtc0
 fi
fi

I have replaced "--localtime" with "-l", don't know if that will fix it.

Another possibility is that /sys/class/rtc/rtc0 does not exist that early in bootup.
Maybe a kernel device driver has to get loaded before that appears.

Actually, you can find out. menu "Shutdown -> Rectify -> Reboot to initrd"
Choose the first radiobutton, then reboot.

At bootup, it will drop out to a terminal in the initrd, and you can see if /sys/class/rtc/rtc0
and /dev/rtc0 exist.

stevie pup
Posts: 209
Joined: Mon May 10, 2021 7:40 pm
Location: Derbyshire, UK
Has thanked: 14 times
Been thanked: 53 times

Re: EasyOS won't save daylight saving time (Solved)

Post by stevie pup »

Looks like it hadn't fixed itself. Next time I booted it up the time was back to being an hour out, so I set Qsync. Next time I booted it was an hour out again! So I set Qsync again, and now it appears to be behaving itself.

All I can think is that I didn't save session the first time I set Qsync, although that doesn't explain how it managed to put itself right on just the one occasion.

I will keep an eye on it and hope for the best, and if it goes haywire again (to quote Arnie) "I'll be back". :)

Post Reply

Return to “EasyOS”