Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
Debian system clock reset hardware (BIOS) clock on boot [SOLVED]
Debian system clock reset hardware (BIOS) clock on boot [SOLVED]
I have 2 boot system Windows and Debian on separate disks. When Debian is loading always reset hardware (BIOS) clock on UTC time. I not be bothered if I use only Debian but whenewe is loading Windows, must always prior go to BIOS settings and set the time.
How to set the system (Debian) not to do that?
I tried solved the problem with hwclock (https://manpages.debian.org/stretch/uti ... .8.en.html) but this do not apply on my system.
How to set the system (Debian) not to do that?
I tried solved the problem with hwclock (https://manpages.debian.org/stretch/uti ... .8.en.html) but this do not apply on my system.
Last edited by jazbar on 2021-08-26 10:36, edited 1 time in total.
My PC: MB MSI 790GX-G65, AMD Phenom II X3, 6 GB RAM, onboard graphic HD3300 DirectX 10, (AMD 790GX chipset)
Re: Debian system clock reset hardware (BIOS) clock on boot
Windows uses local time while Debian uses UTC. You can easily change it on Debian, but then summer/standard time might not automatically change according to your region. So just have that in mind. You can change Windows to use universal time, but is a bit more troublesome.
To set Debian to use local time run
Where set-local-rtc is your local time time zone, for me it is +1. To change back to UTC just run it again with 0 instead.
To check run
To set Debian to use local time run
Code: Select all
timedatectl set-local-rtc 1 --adjust-system-clock
To check run
Code: Select all
timedatectl
- sunrat
- Administrator
- Posts: 6497
- Joined: 2006-08-29 09:12
- Location: Melbourne, Australia
- Has thanked: 118 times
- Been thanked: 476 times
Re: Debian system clock reset hardware (BIOS) clock on boot
I prefer to set Windows to use UTC and leave the hwclock on UTC, which is dead easy and preferable to changing Linux to local time especially for a system with several Linux installations as I have.
Just need to set one registry entry:
Create HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation\RealTimeIsUniversal
with this value:
or just save this as a ".reg" file and click on it to import to Windows registry:
Thanks to https://wiki.archlinux.org/title/System ... ft_Windows
Just need to set one registry entry:
Create HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation\RealTimeIsUniversal
with this value:
Code: Select all
"RealTimeIsUniversal"=dword:00000001
Code: Select all
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation]
"RealTimeIsUniversal"=dword:00000001
“ computer users can be divided into 2 categories:
Those who have lost data
...and those who have not lost data YET ” Remember to BACKUP!
Those who have lost data
...and those who have not lost data YET ” Remember to BACKUP!
-
- Global Moderator
- Posts: 2715
- Joined: 2018-06-20 15:16
- Location: Colorado
- Has thanked: 41 times
- Been thanked: 201 times
Re: Debian system clock reset hardware (BIOS) clock on boot
..another reason not to dual boot!
there is also the older Debian method of /etc/adjtime which is 'UTC' or "LOCAL"
I think that still works, and the preferred methods posted above.
Be careful with the registry hack in windows! I'm sure it works better maybe post XP, don't know.
I still have somewhat current hardware XP's and when setting 'acquisition gadgets' hooked up on usb and serial ports something in the programming reverts the windows clock to bios as local +TZ regardless of the registry setting.
Only a reboot fixes it, so a few years ago I decided XP boxes are XP boxes... Virtual machines do do the job, assume the time is local, pass the devices, work fine.
there is also the older Debian method of /etc/adjtime which is 'UTC' or "LOCAL"
I think that still works, and the preferred methods posted above.
Be careful with the registry hack in windows! I'm sure it works better maybe post XP, don't know.
I still have somewhat current hardware XP's and when setting 'acquisition gadgets' hooked up on usb and serial ports something in the programming reverts the windows clock to bios as local +TZ regardless of the registry setting.
Only a reboot fixes it, so a few years ago I decided XP boxes are XP boxes... Virtual machines do do the job, assume the time is local, pass the devices, work fine.
Re: Debian system clock reset hardware (BIOS) clock on boot
^ ^ ^
Is such GUI app exist in (Debian) Synaptic Package Manager. And if is what is the name of the package?
https://forums.opensuse.org/showthread. ... ost2491919
Is such GUI app exist in (Debian) Synaptic Package Manager. And if is what is the name of the package?
https://forums.opensuse.org/showthread. ... ost2491919
Last edited by jazbar on 2021-08-25 19:13, edited 1 time in total.
My PC: MB MSI 790GX-G65, AMD Phenom II X3, 6 GB RAM, onboard graphic HD3300 DirectX 10, (AMD 790GX chipset)
Re: Debian system clock reset hardware (BIOS) clock on boot
Please stop posting pictures of text. Just cut/paste the text into code tags. Thanks.
Re: Debian system clock reset hardware (BIOS) clock on boot
What should be written or correct in Nano Terminal? RTC = LOCAL time?CwF wrote: ↑2021-08-25 15:14 ..another reason not to dual boot!
there is also the older Debian method of /etc/adjtime which is 'UTC' or "LOCAL"
I think that still works, and the preferred methods posted above.
Be careful with the registry hack in windows! I'm sure it works better maybe post XP, don't know.
I still have somewhat current hardware XP's and when setting 'acquisition gadgets' hooked up on usb and serial ports something in the programming reverts the windows clock to bios as local +TZ regardless of the registry setting.
Only a reboot fixes it, so a few years ago I decided XP boxes are XP boxes... Virtual machines do do the job, assume the time is local, pass the devices, work fine.
GNU nano 3.2 /etc/adjtime
Code: Select all
.000000 1629916542 0.000000
1629916542
UTC
My PC: MB MSI 790GX-G65, AMD Phenom II X3, 6 GB RAM, onboard graphic HD3300 DirectX 10, (AMD 790GX chipset)
Re: Debian system clock reset hardware (BIOS) clock on boot
Should be just LOCAL
Command
timedatectl set-local-rtc 1 --adjust-system-clock
Does that for you
Code: Select all
$ cat /etc/adjtime
0.000000 1622327125 0.000000
1622327125
LOCAL
timedatectl set-local-rtc 1 --adjust-system-clock
Does that for you
set-local-rtc [BOOL]
Takes a boolean argument. If "0", the system is configured to maintain the RTC in universal
time. If "1", it will maintain the RTC in local time instead. Note that maintaining the RTC in
the local timezone is not fully supported and will create various problems with time zone
changes and daylight saving adjustments. If at all possible, keep the RTC in UTC mode. Note that
invoking this will also synchronize the RTC from the system clock, unless --adjust-system-clock
is passed (see above). This command will change the 3rd line of /etc/adjtime, as documented in
hwclock(8).
-
- Global Moderator
- Posts: 2715
- Joined: 2018-06-20 15:16
- Location: Colorado
- Has thanked: 41 times
- Been thanked: 201 times
Re: Debian system clock reset hardware (BIOS) clock on boot
Any one have any idea what the magic numbers are all about?
- sunrat
- Administrator
- Posts: 6497
- Joined: 2006-08-29 09:12
- Location: Melbourne, Australia
- Has thanked: 118 times
- Been thanked: 476 times
Re: Debian system clock reset hardware (BIOS) clock on boot
What was the first reason? I have several boxen with multiple Win/Linux installs. No downsides IMO.
I can assure you the registry entry works in Win 7 and Win 10. I haven't had an XP box for ~12 years to test it.there is also the older Debian method of /etc/adjtime which is 'UTC' or "LOCAL"
I think that still works, and the preferred methods posted above.
Be careful with the registry hack in windows! I'm sure it works better maybe post XP, don't know.
Much easier to set Win for UTC than set the six Linux installs on this box to LOCAL!
“ computer users can be divided into 2 categories:
Those who have lost data
...and those who have not lost data YET ” Remember to BACKUP!
Those who have lost data
...and those who have not lost data YET ” Remember to BACKUP!
-
- Global Moderator
- Posts: 2715
- Joined: 2018-06-20 15:16
- Location: Colorado
- Has thanked: 41 times
- Been thanked: 201 times
Re: Debian system clock reset hardware (BIOS) clock on boot
Sure, I don't disagree, I just don't. First reason, VM's work fine, all fuction available at all times and they talk to each other, dual boot doesn't offer that.
I did deduce the problem with XP years ago with the things I use it for. That need won't ever change, so I learned the vm way to cover the need forever. That machine got old, so I built a new one (ok, more than once) and I put XP on it to cover the need, that I don't need, and turned it off! I always have an XP or two running, but use the VM's. The bare metal XP's are far beyond my E5's vm speed, but I think to slow for it to matter.
I figure modern windows figured out the issue. I do run a Debian on 'XP boxes ' for testing things, never need to leave it on for long.
Re: Debian system clock reset hardware (BIOS) clock on boot
Reading in hwclock manualAny one have any idea what the magic numbers are all about?
The Adjtime File
While named for its historical purpose of controlling adjustments only, it actually contains other
information used by hwclock from one invocation to the next.
The format of the adjtime file is, in ASCII:
Line 1: Three numbers, separated by blanks: 1) the systematic drift rate in seconds per day, float‐
ing point decimal; 2) the resulting number of seconds since 1969 UTC of most recent adjustment or
calibration, decimal integer; 3) zero (for compatibility with clock(8)) as a floating point decimal.
Line 2: One number: the resulting number of seconds since 1969 UTC of most recent calibration. Zero
if there has been no calibration yet or it is known that any previous calibration is moot (for exam‐
ple, because the Hardware Clock has been found, since that calibration, not to contain a valid
time). This is a decimal integer.
Line 3: "UTC" or "LOCAL". Tells whether the Hardware Clock is set to Coordinated Universal Time or
local time. You can always override this value with options on the hwclock command line.
You can use an adjtime file that was previously used with the clock(8) program with hwclock.
Re: Debian system clock reset hardware (BIOS) clock on boot
"nano etc/adjtime" set to local
Result:
It works. Who cares if summer and winter time should be set manually in BIOS as long this is home PC.
Thanks for help.
Code: Select all
000000 1629916542 0.000000
1629916542
LOCAL
Code: Select all
jazbar@ABC:~$ timedatectl
Local time: Thu 2021-08-26 12:23:34 CEST
Universal time: Thu 2021-08-26 10:23:34 UTC
RTC time: Thu 2021-08-26 12:23:32
Time zone: Europe/Ljubljana (CEST, +0200)
System clock synchronized: no
NTP service: active
NTC in local TZ: yes
Warning: The system is configured to read the RTC time in the local time zone.
This mode cannot be fully supported. It will create various problems
with time zone changes and daylight saving time adjustments. The RTC
time is never updated, it relies on external facilities to maintain it.
If at all possible, use RTC in UTC by calling
'timedatectl set-local-rtc 0'.
jazbar@ABC:~$
Thanks for help.
My PC: MB MSI 790GX-G65, AMD Phenom II X3, 6 GB RAM, onboard graphic HD3300 DirectX 10, (AMD 790GX chipset)