Time shifting

Noticed something odd tonight. Not sure about the ROW, but in the US we have some odd obsession with screwing with the time, twice a year. (Daylight savings time. LOL as if…)

In any case, I have work files saved on a USB stick.
I have backups of all those files on my Linux harddrive.

Just noticed that the “modified” time of the files on the harddrive all now show a time one hour off from the time shown for all those files that were/are stored on the USB stick. The Harddrive files have all “sprung forward”. Anyone else think that is weird?

Why would the time of the files already stored on a harddrive change by one hour? Shouldn’t they stay the same (until modified of course) regardless of the system clock changing?

Are these files on a Windows partition and/or are you dual booting?

And to add to ken_yap’s suggestion: Isthere a non Linux file system (like NTFS) on the USB stick?

The way Unix/Linux handles time is very different from how others do it (not only MS, I remember that at my working place the IBM Mainframe had to be rebooted completely at the change from winter to summer time and vv.).

In Unix/Linux all timestamps are registered in UTC (in fact the number of ticks since the 1970-01-01 (the Unix Epoch). What you see as date/time of e.g. the last change of a file, is this timestamp converted to the time zone (including DST when needed) your process finds in its environment. There is a system default for this (that is the time root sees) and every user has its own one (when I have a userid on your system and do a remote login, I nevertheless like to see my local time).

Windows does not have such a thing, but always works in local time (at least that is my impression, I do not know much about MS Windows). And as such the timestamps on an MS Filesystem must differ from those on a Unix/Linux system. Now I do not know how Linux handles time stamps (interpreting and writing) on e.g. an NTFS file system, but I can understand that something must go wrong here and that not much can be done about it. Using non Linux file system types always comes at a prize.

Also when you have a multi boot system with an MS Windows type OS one should set the “Set hardware clock to …” at local time, because else the windows system will on boot have the wrong time. Of course, when you set this, Linux knows and takes care of this to correct its own system time on boot.

There it is.
USB stick = vfat for storing files created on Windows XP systems at work.
Thanks a lot for the explanation!
Does make sense now knowing the details.