[opensuse] mount timestamps - use as is
Hello: This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs. I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST). Some of you might remember that I had problems with vfat time stamps in linux earlier. Correct original timestamps of files are crucial for me. When I make a photo with my camera or record voice with a voice recorder or take a note on mobile phone, time stamps recorded are local timestamp. For me those time stamp have sense in local time only. If the file was saved at 3 pm, for me it is 3 pm, independently of the time zone and summer/winter timeshift. Unfortunately linux can't handle this issue, because when it uses UTC, it converts all time stamps to UTC, and adjust the time stamps according to time zone and summer/winter timeshift. Because of this I decided to change my system to use local time. I though if I use system local time I don't have to worry about timestamps shifting when I mount vfat volumes. Now it turned out, this is not the case. If I mount a vfat volume, the time stamps for the files that were made in the same timeshift are correct, but of those were made in the other timeshift are off by 1 hour. (For example in summer, timestamps of files recorded in summer are correct, but timestamps of files recorded in winter are less by an hour.) For me this has no sense, and causes plus work, because before copying the files I have to check if they were taken in summer time of winter time. I have to mount the filesystem twice, once using specific mount options, that is I can't use simple automount. This is tedious and annoying. Is there any way I can set linux to mount vfat to show the time stamps 'as is', without adjusting them according to DST winter time/summer time? Once more, my system is set to local time, that is time zones don't play here. I use openSUSE Leap 42.2 and 15.1. Thanks, Istvan -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Op zaterdag 2 mei 2020 22:23:36 CEST schreef Istvan Gabor:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST). You're completely wrong. Timestamps are created as number of seconds since the epoch: 1970-01-01 00:00:00 . For the record: we have DST now, pictures I took of fireworks a couple of minutes after the new year started, show the right date and time, no matter if I look at the timestamp in winter or summer. Where your reasoning implies a change in that number of seconds. Which doesn't happen. You can check in 'man ctime'.
-- Gertjan Lettink a.k.a. Knurpht openSUSE Forums Team -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Quoting Knurpht-openSUSE <knurpht@opensuse.org>:
Op zaterdag 2 mei 2020 22:23:36 CEST schreef Istvan Gabor:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST). You're completely wrong. Timestamps are created as number of seconds since the epoch: 1970-01-01 00:00:00 . For the record: we have DST now, pictures I took of fireworks a couple of minutes after the new year started, show the right date and time, no matter if I look at the timestamp in winter or summer. Where your reasoning implies a change in that number of seconds. Which doesn't happen. You can check in 'man ctime'.
This is true for Linux native file systems. Are you sure it's true for MS-DOS VFAT? It's clear from a quick search that VFAT timestamps are in local time. Jeffrey -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 02/05/2020 23.41, Jeffrey L. Taylor wrote:
Quoting Knurpht-openSUSE <knurpht@opensuse.org>:
Op zaterdag 2 mei 2020 22:23:36 CEST schreef Istvan Gabor:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST). You're completely wrong. Timestamps are created as number of seconds since the epoch: 1970-01-01 00:00:00 . For the record: we have DST now, pictures I took of fireworks a couple of minutes after the new year started, show the right date and time, no matter if I look at the timestamp in winter or summer. Where your reasoning implies a change in that number of seconds. Which doesn't happen. You can check in 'man ctime'.
This is true for Linux native file systems. Are you sure it's true for MS-DOS VFAT? It's clear from a quick search that VFAT timestamps are in local time.
He is talking only of Linux. And I concur. VFAT is not a Linux filesystem, so it uses local time always, with no knowledge of timeshift. Not even any idea of the time zone that is "local". -- Cheers / Saludos, Carlos E. R. (from 15.1 x86_64 at Telcontar)
On 02/05/2020 22.23, Istvan Gabor wrote:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST).
Some of you might remember that I had problems with vfat time stamps in linux earlier.
Correct original timestamps of files are crucial for me.
When I make a photo with my camera or record voice with a voice recorder or take a note on mobile phone, time stamps recorded are local timestamp. For me those time stamp have sense in local time only. If the file was saved at 3 pm, for me it is 3 pm, independently of the time zone and summer/winter timeshift.
Well, not independently: I have to manually shift one hour on my cameras at the correct date - and I often forget till I start shooting. If I don't adjust the camera, the local time on the camera is one hour off with the wall clock.
Unfortunately linux can't handle this issue, because when it uses UTC, it converts all time stamps to UTC, and adjust the time stamps according to time zone and summer/winter timeshift.
Because of this I decided to change my system to use local time. I though if I use system local time I don't have to worry about timestamps shifting when I mount vfat volumes.
It is not possible to tell a Linux system to use local time.
Now it turned out, this is not the case. If I mount a vfat volume, the time stamps for the files that were made in the same timeshift are correct, but of those were made in the other timeshift are off by 1 hour.
(For example in summer, timestamps of files recorded in summer are correct, but timestamps of files recorded in winter are less by an hour.)
For me this has no sense, and causes plus work, because before copying the files I have to check if they were taken in summer time of winter time. I have to mount the filesystem twice, once using specific mount options, that is I can't use simple automount. This is tedious and annoying.
Is there any way I can set linux to mount vfat to show the time stamps 'as is', without adjusting them according to DST winter time/summer time?
Not possible. They are different paradigms. A DOS system runs in local time. A Linux system runs (can be considered to run) in UTC, and calculates the local time. Both display the same time. You could put your camera on UTC instead, and in Linux do the same for the user that mounts the camera.
Once more, my system is set to local time, that is time zones don't play here.
Impossible, sorry. Linux runs in UTC. If you artificially change that time to be the local time, Linux still considers it is running in UTC and calculates the local time. Havoc. -- Cheers / Saludos, Carlos E. R. (from 15.1 x86_64 at Telcontar)
Op zaterdag 2 mei 2020 22:55:17 CEST schreef Carlos E. R.:
On 02/05/2020 22.23, Istvan Gabor wrote:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST).
Some of you might remember that I had problems with vfat time stamps in linux earlier.
Correct original timestamps of files are crucial for me.
When I make a photo with my camera or record voice with a voice recorder or take a note on mobile phone, time stamps recorded are local timestamp. For me those time stamp have sense in local time only. If the file was saved at 3 pm, for me it is 3 pm, independently of the time zone and summer/winter timeshift.
Well, not independently: I have to manually shift one hour on my cameras at the correct date - and I often forget till I start shooting. If I don't adjust the camera, the local time on the camera is one hour off with the wall clock.
Depends on the camera. Modern ones adjust the time display to DST, older don't. That's when the issue arises, since the older ones calculate the timestamp from the internal clock. That results in the timestamps being off if one doesn't adjust their clock. The computer doesn't know about that, so will display the wrong timestamp half of the year if you don't.
Unfortunately linux can't handle this issue, because when it uses UTC, it converts all time stamps to UTC, and adjust the time stamps according to time zone and summer/winter timeshift.
Because of this I decided to change my system to use local time. I though if I use system local time I don't have to worry about timestamps shifting when I mount vfat volumes.
It is not possible to tell a Linux system to use local time.
Now it turned out, this is not the case. If I mount a vfat volume, the time stamps for the files that were made in the same timeshift are correct, but of those were made in the other timeshift are off by 1 hour.
(For example in summer, timestamps of files recorded in summer are correct, but timestamps of files recorded in winter are less by an hour.)
For me this has no sense, and causes plus work, because before copying the files I have to check if they were taken in summer time of winter time. I have to mount the filesystem twice, once using specific mount options, that is I can't use simple automount. This is tedious and annoying.
Is there any way I can set linux to mount vfat to show the time stamps 'as is', without adjusting them according to DST winter time/summer time?
Not possible. They are different paradigms.
A DOS system runs in local time. A Linux system runs (can be considered to run) in UTC, and calculates the local time. Both display the same time.
You could put your camera on UTC instead, and in Linux do the same for the user that mounts the camera.
Once more, my system is set to local time, that is time zones don't play here.
Impossible, sorry.
Linux runs in UTC. If you artificially change that time to be the local time, Linux still considers it is running in UTC and calculates the local time. Havoc.
-- Gertjan Lettink a.k.a. Knurpht openSUSE Forums Team -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Saturday, 2020-05-02 at 23:07 +0200, Knurpht-openSUSE wrote:
Op zaterdag 2 mei 2020 22:55:17 CEST schreef Carlos E. R.:
On 02/05/2020 22.23, Istvan Gabor wrote:
Hello:
When I make a photo with my camera or record voice with a voice recorder or take a note on mobile phone, time stamps recorded are local timestamp. For me those time stamp have sense in local time only. If the file was saved at 3 pm, for me it is 3 pm, independently of the time zone and summer/winter timeshift.
Well, not independently: I have to manually shift one hour on my cameras at the correct date - and I often forget till I start shooting. If I don't adjust the camera, the local time on the camera is one hour off with the wall clock.
Depends on the camera. Modern ones adjust the time display to DST, older don't.
What do you consider "old"? I have a pocket Samsung camera, bought January 2011, and the other is a Nikon D3200, bought August 2015. I should consider that "modern", and neither changes the clock automatically :-/ The phones yes, of course they adjust the time. My theory is that a camera with GPS will adjust the time. Or one which CPU can run when nominally powered off - but the firmware could adjust for DST same as a Windows computer does, when first powered up after the time shift. Maybe it depends on brands? But Samsung is a powerful company, should have no problem designing quality firmware ;-)
That's when the issue arises, since the older ones calculate the timestamp from the internal clock. That results in the timestamps being off if one doesn't adjust their clock. The computer doesn't know about that, so will display the wrong timestamp half of the year if you don't.
Exactly. - -- Cheers, Carlos E. R. (from openSUSE 15.1 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCXq3luRwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfV5FkAn16QUlI6O12wekdWo96X a7DZVNIAAJ9XYvHi1KJv1JbFGvdGTPulLOfrIQ== =kOuQ -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Istvan, et al -- ...and then Carlos E. R. said... % ... % % You could put your camera on UTC instead, and in Linux do the same % for the user that mounts the camera. [snip] +1 I set all of my cameras, recorders, wifi-only cell phones, and even some computers at UTC, expect them to be stamped (and often named, which is why this becomes interesting) accordingly, and let anything looking at the files translate for me however I set my $TZ. Let Linux do its job of showing you accurate data in the paradigm you wish, and let everything else (including Linux :-) just work on knowing the UTC time. My only beef is in the summer with some phones don't know how to find UTC and just forward an hour with GMT Daylight Saving Time *sigh* Good luck! :-) :-D -- David T-G See http://justpickone.org/davidtg/email/ See http://justpickone.org/davidtg/tofu.txt -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
I use the standard set by the camera makers, which is that the camera is always set to local time. I routinely copy all photos off my camera/sdcard to my local drive. The software that does the copy, either digikam or my own script, works from the dates in the EXIF. Using the EXIF is the safest approach. Software, such as digikam, can batch apply corrections to the EXIF for the clock if I've forgotten to keep the camera set correctly. Digikam can also deal with inserting separate GPS into the EXIF correctly dealing with the different time formats. My camera automatically sets the local date-time when I connect it to my phone, I just have to remember to connect it once every time daylight saving changes. I've not traveled across timezones with this setup, so that might prove interesting. The best approach is probably to be found by searching for what professional photographers do. Michael On Sunday 03 May 2020, Carlos E. R. wrote:
On 02/05/2020 22.23, Istvan Gabor wrote:
Hello:
This question applies to openSUSE Leap 42.2-15.1 versions and any modern linux OSs.
I would like if I could mount vfat volumes so that the time stamps would be shown 'as is' and not adjusted according to daylight saving time (DST).
Some of you might remember that I had problems with vfat time stamps in linux earlier.
Correct original timestamps of files are crucial for me.
When I make a photo with my camera or record voice with a voice recorder or take a note on mobile phone, time stamps recorded are local timestamp. For me those time stamp have sense in local time only. If the file was saved at 3 pm, for me it is 3 pm, independently of the time zone and summer/winter timeshift.
Well, not independently: I have to manually shift one hour on my cameras at the correct date - and I often forget till I start shooting. If I don't adjust the camera, the local time on the camera is one hour off with the wall clock.
Unfortunately linux can't handle this issue, because when it uses UTC, it converts all time stamps to UTC, and adjust the time stamps according to time zone and summer/winter timeshift.
Because of this I decided to change my system to use local time. I though if I use system local time I don't have to worry about timestamps shifting when I mount vfat volumes.
It is not possible to tell a Linux system to use local time.
Now it turned out, this is not the case. If I mount a vfat volume, the time stamps for the files that were made in the same timeshift are correct, but of those were made in the other timeshift are off by 1 hour.
(For example in summer, timestamps of files recorded in summer are correct, but timestamps of files recorded in winter are less by an hour.)
For me this has no sense, and causes plus work, because before copying the files I have to check if they were taken in summer time of winter time. I have to mount the filesystem twice, once using specific mount options, that is I can't use simple automount. This is tedious and annoying.
Is there any way I can set linux to mount vfat to show the time stamps 'as is', without adjusting them according to DST winter time/summer time?
Not possible. They are different paradigms.
A DOS system runs in local time. A Linux system runs (can be considered to run) in UTC, and calculates the local time. Both display the same time.
You could put your camera on UTC instead, and in Linux do the same for the user that mounts the camera.
Once more, my system is set to local time, that is time zones don't play here.
Impossible, sorry.
Linux runs in UTC. If you artificially change that time to be the local time, Linux still considers it is running in UTC and calculates the local time. Havoc.
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
participants (6)
-
Carlos E. R.
-
David T-G
-
Istvan Gabor
-
Jeffrey L. Taylor
-
Knurpht-openSUSE
-
Michael Hamilton