LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   samba - windows files lose "created on" date stamp when moved to samba share on linux (http://www.linuxquestions.org/questions/linux-software-2/samba-windows-files-lose-created-on-date-stamp-when-moved-to-samba-share-on-linux-752505/)

jaredk51 09-03-2009 04:30 PM

samba - windows files lose "created on" date stamp when moved to samba share on linux
 
I know linux doesn't support "created on" date stamps consequently when copying or moving files from windows hosts via samba shares to linux box running 2.6.18-128.el5 I lose the 'created on' date stamp for each file.

Is there a config setting in smb.conf option to retain this date stamp or some other work around.

Thanks in advance

mostlyharmless 09-30-2009 05:35 PM

If you use the -p parameter while copying with cp, it should preserve the date. (see man cp) Or am I misunderstanding the question?

chrism01 09-30-2009 08:10 PM

I agree, try cp -p with one file and let us know what happens. Could be useful for all of us.
Use stat to check all 3 times (atime/ctime/mtime) http://linux.die.net/man/1/stat

lutusp 10-01-2009 02:40 AM

Quote:

Originally Posted by jaredk51 (Post 3668808)
I know linux doesn't support "created on" date stamps consequently when copying or moving files from windows hosts via samba shares to linux box running 2.6.18-128.el5 I lose the 'created on' date stamp for each file.

Is there a config setting in smb.conf option to retain this date stamp or some other work around.

Thanks in advance

The problem is that Linux (and Unices in general) don't have a "created-on" date stamp. All appearance to the contrary, the "ctime" date field only reflects the last time a file's inode was changed, which could change for any number of reasons.

This means if you succeeded in getting a creation time, you would have nowhere to put it -- at least, nowhere reliable and immutable.

archtoad6 11-09-2009 04:00 PM

Quote:

Originally Posted by chrism01 (Post 3702626)
I agree, try cp -p with one file and let us know what happens. Could be useful for all of us.
Use stat to check all 3 times (atime/ctime/mtime) http://linux.die.net/man/1/stat

jaredk51, I take it your test was unsuccessful.

jaredk51 02-19-2010 03:13 PM

Sorry guys.... this got pushed above me in the hierarchy and I never looked back.
Its a non-issue for us anymore so I didn't try the fix.

thanks for the replies tho.


All times are GMT -5. The time now is 11:43 AM.