Local time

Write suggestions and new ideas in here
More ideas here http://community.linuxmint.com/idea/welcome
Forum rules
  • Only post ideas here that are specifically about the Linux Mint distribution or its websites.
  • So that developers and users from any distribution can discuss ideas in one place, post ideas about improving software to the collaboration website for that software instead.
Post Reply
FrostyRussian
Level 1
Level 1
Posts: 15
Joined: Tue Sep 05, 2017 2:00 pm

Local time

Post by FrostyRussian » Wed Apr 25, 2018 6:24 am

Im using dual boot at the moment, and im in GMT +2 timezone. Whenever i switch systems my clock goes nuts. Searched a bit and found problem.
Windows is saving time in Local Time, while Ubuntu (and mint) in UTC, so solution is to make one of them use the other one's format.
For ubuntu its a simple solution

Code: Select all

timedatectl set-local-rtc 1
and windows isnt any harder, but since Mint's aim is to be user friendly and best cross over to linux system i think it would be nice to handle these at install (if detected there is windows install).

Cosmo.
Level 23
Level 23
Posts: 17829
Joined: Sat Dec 06, 2014 7:34 am

Re: Local time

Post by Cosmo. » Wed Apr 25, 2018 6:53 am

How shall the installer know, whether you want to do the change in Windows or Linux?

User avatar
Pierre
Level 17
Level 17
Posts: 7569
Joined: Fri Sep 05, 2008 5:33 am
Location: Perth, AU.

Re: Local time

Post by Pierre » Wed Apr 25, 2018 7:25 am

some Linux installers Do Allow for the Difference,
but, it's also up to the New User to know that there is an issue at hand:
- and most Don't - - so they Do get caught Out.
:(
and even the more Experienced Folk, do also get caught - -when this issue slips their Mind.
:roll:
Image
Please edit your original post title to include [SOLVED] - when your problem is solved!
and DO LOOK at those Unanswered Topics - - you may be able to answer some!.

FrostyRussian
Level 1
Level 1
Posts: 15
Joined: Tue Sep 05, 2017 2:00 pm

Re: Local time

Post by FrostyRussian » Tue May 01, 2018 10:24 am

Cosmo. wrote:
Wed Apr 25, 2018 6:53 am
How shall the installer know, whether you want to do the change in Windows or Linux?
Since we already have Windows installed, and we are right now installing Linux, change should happen in Linux and not Windows.

User avatar
sdibaja
Level 5
Level 5
Posts: 665
Joined: Sun May 08, 2011 12:57 pm
Location: Baja California, Mexico

Re: Local time

Post by sdibaja » Tue May 01, 2018 10:58 am

FrostyRussian wrote:
Tue May 01, 2018 10:24 am
Cosmo. wrote:
Wed Apr 25, 2018 6:53 am
How shall the installer know, whether you want to do the change in Windows or Linux?
Since we already have Windows installed, and we are right now installing Linux, change should happen in Linux and not Windows.
If the Linux Mint installer does Not give you that option it should... perhaps it is there but not too clear.

BTW: all of my systems are on GMT or Universal time, whatever it is called now... When I boot Windows it does show the time wrong, but it automatically updates (makes local time adjustment to the display) with the internet time server after a few minutes. I think that is Windows default, but maybe I had to do that, I forget.

Cosmo.
Level 23
Level 23
Posts: 17829
Joined: Sat Dec 06, 2014 7:34 am

Re: Local time

Post by Cosmo. » Tue May 01, 2018 4:19 pm

FrostyRussian wrote:
Tue May 01, 2018 10:24 am
Since we already have Windows installed, and we are right now installing Linux, change should happen in Linux and not Windows.
If you prefer it this way this does not mean, that everybody will like it this way. There might be the case, that the user has changed it in Windows already, in this case it would be bad idea.

FrostyRussian
Level 1
Level 1
Posts: 15
Joined: Tue Sep 05, 2017 2:00 pm

Re: Local time

Post by FrostyRussian » Wed May 02, 2018 8:14 pm

Cosmo. wrote:
Tue May 01, 2018 4:19 pm
FrostyRussian wrote:
Tue May 01, 2018 10:24 am
Since we already have Windows installed, and we are right now installing Linux, change should happen in Linux and not Windows.
If you prefer it this way this does not mean, that everybody will like it this way. There might be the case, that the user has changed it in Windows already, in this case it would be bad idea.
I dont prefer it this or that way, its all the same to me, a simple command in linux or reg file in windows (notepad/sublime or any other IDE) - it may take me a few minutes to find exact command or registry content (depending on where im gonna do it) but it wont make any difference for me.

Its just pure and simple logic. We already have working system (Windows), and we are installing new one. Since we decided to keep old system in working state then we dont want to mess with it and change only what we must (like boot file). So we make adjustment in new system (its our linux as second boot), and if something goes awry here, we dont care much since we have old system still working. Asking a simple question whether user wants to use Local or UCT during install is more then appropriate (as long as its explained why he has to choose - that is windows by default uses local time). Even adding it to welcome screen is ok by me, but then as i know most people they just dont care and close it without reading a single line just like when installing software (and shitload of adware with it).

User avatar
Pierre
Level 17
Level 17
Posts: 7569
Joined: Fri Sep 05, 2008 5:33 am
Location: Perth, AU.

Re: Local time

Post by Pierre » Wed May 02, 2018 10:06 pm

Some Linux Installers will ask the question whether user wants to use Local or UCT during install,,
but the reason is not always given, and it does take a little experience with Linux Systems,
in order to know why the question is being asked, let alone what the correct answer should be.

the easy answer, is to simply let the Internet-time auto-update each system after it is booted up.

the other easy option, is to run a command in Terminal on the Linux System:
https://www.digitalocean.com/community/ ... quickstart
is one way to do that.
Image
Please edit your original post title to include [SOLVED] - when your problem is solved!
and DO LOOK at those Unanswered Topics - - you may be able to answer some!.

User avatar
lsemmens
Level 6
Level 6
Posts: 1158
Joined: Wed Sep 10, 2014 9:07 pm
Location: Rural South Australia

Re: Local time

Post by lsemmens » Wed May 02, 2018 10:07 pm

Would it not be simpler just to pick up the time from BIOS and then, once installation is finished and time zone set, automatically update to that timezone. Which, I believe is what most OS, including Windoze and Mint, do. I've never had any real issues when installing an OS. The most I have ever had to do is set for ACDST.
Kernel: 4.15.0-36-generic x86_64 bits: 64
Desktop: Cinnamon 3.8.9
Distro: Linux Mint 19 Tara

Laptop T4500 Dualcore 4Gb RAM
Server AMD Phenom 9650 - GEForce 9400GT 6Gb RAM
+ three other Linux Mint machines
Out of my mind - please leave a message

User avatar
sdibaja
Level 5
Level 5
Posts: 665
Joined: Sun May 08, 2011 12:57 pm
Location: Baja California, Mexico

Re: Local time

Post by sdibaja » Wed May 02, 2018 10:08 pm

just keep it simple

https://wiki.debian.org/TimeZoneChanges

Code: Select all

# dpkg-reconfigure tzdata

Current default time zone: 'America/Tijuana'
Local time is now:      Wed May  2 19:07:07 PDT 2018.
Universal Time is now:  Thu May  3 02:07:07 UTC 2018.

Cosmo.
Level 23
Level 23
Posts: 17829
Joined: Sat Dec 06, 2014 7:34 am

Re: Local time

Post by Cosmo. » Thu May 03, 2018 5:28 am

FrostyRussian wrote:
Wed May 02, 2018 8:14 pm
Asking a simple question whether user wants to use Local or UCT
The question may sound(!) simple, but I bet every amount, that a huge number would not know, what and why to select. We would see numerous question about the criteria for this or that choice. Those questions in the forum are not a real problem. The real problem is, that the user does not get further in the installation process, because the installer would wait for the answer and the user does not know, what to choose.

User avatar
shawnhcorey
Level 3
Level 3
Posts: 191
Joined: Thu Jun 17, 2010 11:23 am
Location: The Great White North
Contact:

Re: Local time

Post by shawnhcorey » Thu May 03, 2018 6:47 am

Cosmo. wrote:
Thu May 03, 2018 5:28 am
FrostyRussian wrote:
Wed May 02, 2018 8:14 pm
Asking a simple question whether user wants to use Local or UCT
The question may sound(!) simple, but I bet every amount, that a huge number would not know, what and why to select. We would see numerous question about the criteria for this or that choice. Those questions in the forum are not a real problem. The real problem is, that the user does not get further in the installation process, because the installer would wait for the answer and the user does not know, what to choose.
There is nothing simple about time. Even Linux gets it wrong.
Don't stop where the ink does.

DAMIEN1307
Level 6
Level 6
Posts: 1147
Joined: Tue Feb 21, 2017 8:13 pm
Location: Alamogordo, New Mexico

Re: Local time

Post by DAMIEN1307 » Thu May 03, 2018 8:23 am

i dont see the problem...my computers all run UTC in the bios but run local time on the OS...my "thought" on this was to just leave it this way thinking that this may be related to system updates etc from update servers etc may rely on this for OS update purposes??? could be wrong of course but it seems logical that this could possibly be a reason for it?...DAMIEN
ORDO AB CHAO

rene
Level 8
Level 8
Posts: 2226
Joined: Sun Mar 27, 2016 6:58 pm

Re: Local time

Post by rene » Thu May 03, 2018 4:16 pm

FrostyRussian wrote:
Wed May 02, 2018 8:14 pm
Its just pure and simple logic.
Unfortunately not all that simple: keeping the RTC on local time creates a few unsolvable issues specifically/especially in light of DST. RTC on UTC or local time is not a matter of equally valid choices: the Windows choice is the technically worse one. For a generic description of the issue(s) see for example http://www.cl.cam.ac.uk/~mgk25/mswish/ut-rtc.html.

However, up to and including release 17 Mint chose to not deeply care and assumed the RTC to be on local time -- at the very least when the installer knew it was going to be dual-booting. Not completely sure about that latter bit any more but I believe it did in fact use UTC when not dual-booting (changing to the other choice was a matter of changing a setting under /etc/default). That is, Mint 17 behaved as you would seem to like it to behave. This however changed with Mint 18 and specifically with the use of systemd. To quote the systemd 216 announcement, https://lwn.net/Articles/609740/,
systemd will no longer inform the kernel about the current timezone, as this is necessarily incorrect and racy as the kernel has no understanding of DST and similar concepts. This hence means FAT timestamps will be always considered UTC, similar to what Android is already doing. Also, when the RTC is configured to the local time (rather than UTC) systemd will never synchronize back to it, as this might confuse Windows at a later boot.
We've seen previous topics on the forums here about for example pictures on a FAT-formatted SD card from a digital camera now showing incorrect timestamps due to this. Initially opinions might be seen to legitimately vary and certainly systemd has a very worrying tendency to dump its issues on everyone else, but once you investigate you do in fact quickly come to the conclusion that RTC on local really is the technically wrong choice and should not be made without the user explicitly telling you that he's fine with technically wrong choices just to appease Windows.

Which, don't get me wrong, was exactly what I myself did when I was dual-booting Mint 17 with Windows 7 for a while, in a "never expect Windows to get anything right and just fix up its nonsense Linux-side" manner, but with systemd causing the generic/theoretical issues with local time to become very practical ones, there's no other possible default choice than UTC. Sure, this creates an issue for unaware dual-booters, but so does local time the first time said user mounts an externally created FAT filesystem. That one moreover much harder to identify.

And now ask yourself if YOU would provide for a UTC/Local installer choice that explained all that crap. UTC it is, I'd say...

FrostyRussian
Level 1
Level 1
Posts: 15
Joined: Tue Sep 05, 2017 2:00 pm

Re: Local time

Post by FrostyRussian » Thu May 03, 2018 6:37 pm

I do agree that UTC is better since its universal and we dont have to know which timezone was used when timestamp was saved or whatever it was used for, while local time is...well just local... And we ALL know that Windows (read microsoft) is a problem, if it wasnt we wouldnt be here discussing these :D

Anyway, i didnt know that keeping RTC on local time can cause problems. I guess that is one of downsides for my suggestion.
And its not that hard to explain why we ask these question and downsides of it. But then there must be simple solution, maybe just simple radio choice with next button. Ask user what to do and add comment "If you dont know what it is, just leave it at default and press next, you can always change it later".

User avatar
shawnhcorey
Level 3
Level 3
Posts: 191
Joined: Thu Jun 17, 2010 11:23 am
Location: The Great White North
Contact:

Re: Local time

Post by shawnhcorey » Thu May 03, 2018 7:26 pm

FrostyRussian wrote:
Thu May 03, 2018 6:37 pm
And we ALL know that Windows (read microsoft) is a problem, if it wasnt we wouldnt be here discussing these :D
Windows is a problem because it came from DOS. Back when Microsoft started, computers weren't connected to the internet. So, time was kept as local time. Windows kept the DOS conventions so the file times would be the same. But now, it has become a problem.

It is really amazing the number of problems that backward compatibility causes.
Don't stop where the ink does.

Prlwytzkofski
Level 1
Level 1
Posts: 5
Joined: Thu Sep 29, 2016 5:03 am

Re: Local time

Post by Prlwytzkofski » Mon Oct 29, 2018 10:17 am

It may be handy to know that Linux by default fetches time from a time server and set the RTC to UTC and then according to the tzdata and locale the displayed time to the zone chosen during installation.

Windows does the opposit: On boot it fetches the time from the RTC and sets the displayed clock accordingly. Then, after fetching the time from a time server Windows resets the diplayed time in the GUI and SETS THE RTC to local time!

After a reboot, in a dual boot situation, Linux sets the RTC back to UTC. In my view it's Windows that should not touch the RTC at all and leave it to UTC, right?

Well a simple addition of one registry key in Windows does exactly that: Copy these lines in a plain text file called utc.reg and import it or add it straight into the registry yourself with regedit:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation] “RealTimeIsUniversal”=dword:00000001

After this reg.setting Windows will behave like *nix. Oh BTW Apple does the same as MS but no idea how to fix that. This works, I tested it on several dual boot systems.

Cheers,
Peter

Post Reply

Return to “Suggestions & New Ideas”