Hi

Originally Posted by
HugoRune
Hi all,
Is there a way to have a network share on an ubuntu file server that supports preserving the creation date of files, and presenting that information to any accessing windows clients.
You may have to write something yourself to do this. There is no easy way as far as i am aware. Others will correct me if i am ill informed.
I know that linux filesystems only store modified-date and last-accessed-date, so there is no easy way to preserve this information. Is there a workaround for that?
Actually this is not true. Certainly ext4 stores the file creation time (crtime) but there is no easy way to get to it.
Take a look at this.
Code:
matthew@matthew-Aspire-7540:~$ sudo debugfs -R "stat /home/matthew/examples.desktop" /dev/sda2
debugfs 1.42 (29-Nov-2011)
Inode: 159041 Type: regular Mode: 0644 Flags: 0x80000
Generation: 1786925867 Version: 0x00000000:00000001
User: 1000 Group: 1000 Size: 179
File ACL: 0 Directory ACL: 0
Links: 1 Blockcount: 8
Fragment: Address: 0 Number: 0 Size: 0
ctime: 0x4f05d402:e179809c -- Thu Jan 5 16:46:58 2012
atime: 0x4f466a18:9564497c -- Thu Feb 23 16:32:24 2012
mtime: 0x4f05d402:e179809c -- Thu Jan 5 16:46:58 2012
crtime: 0x4f05d402:e179809c -- Thu Jan 5 16:46:58 2012
Size of extra inode fields: 28
EXTENTS:
(0):5
matthew@matthew-Aspire-7540:~$
You can get a files creation time using debugfs, however this is not exactly straight forward.
None of the standard commands currently return the crtime as far as i am aware. Certainly they never used to.
In summation, you can get the creation time but you may have to do some work to get it and that you will have to write your self.
Bonus if that workaround works with encFS on the underlying file system.
Can i have the wooden spoon ? 
Kind regards
Bookmarks