[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: time zone and UTC issue [rant]



Ralf Mardorf <ralf.mardorf@rocketmail.com> writes:

> spinymouse@q:~$ ls -l /media/spinymouse/INTENSO/
> total 32
> -rw-r--r-- 1 spinymouse spinymouse   304 Oct 22  2011 B22OCT11.CMO
> -rw-r--r-- 1 spinymouse spinymouse   304 Sep 30  2011 B30SEP11.CMO
> -rw-r--r-- 1 spinymouse spinymouse 15644 Nov 10  2011 Hakle-Geld-zurück.odt
> -rw-r--r-- 1 spinymouse spinymouse    33 Oct 13 23:11 Ubuntu_Studio_USB_stick_test.txt
> -rw-r--r-- 1 spinymouse spinymouse    30 Oct 13 23:11 Ubuntu_Studio_USB_stick_test.txt~
> 
> Nautilus does show time and date for all files of the FAT formatted USB
> stick. I'm not sure if time and date will differ, if I switch local and
> I won't test it now. Only the first two files are from the BIOS, the
> other 3 files are from Linux installs.

There seems to be another wrong assumption here.  Both, ls and
nautilus can show the time (not only date) of all files.  By default,
ls -l shows the date including the year if the file is older than 6
months, and the date without the year but with time, otherwise.

With GNU ls, you can use --time-style=long-iso to get minutes and
--time-style=full-iso to get the full time stamp including even
seconds and nano seconds for each file.

This has nothing to with the type of file system the file resides on.
The kernel hides the details of file systems, e.g. the time stamp
representation.  If offers the same interface for all file systems,
for ext2/3/4, vfat, iso9660, and all other file system types.
In this case, it is stat(2) defined by POSIX, which gives the file
time stamp as a POSIX time_t, i.e. in seconds.  Linux and GNU ls use
an extension that gives the time as POSIX struct timespec, i.e. in
seconds and nano seconds.

urs


Reply to: