Copying a set of files through CIFS from Linux to Windows 7 to preserve the timestamp
Hello All,
I am trying to copy a bunch of files from a Fedora 19 Linux server to a Windows 7 machine. I have successfully set up SAMBA/CIFS to talk from the Linux server to the Windows machine, but it does not replicate the date/time stamps of the files. It looks like it replicates the date/time stamps of the directories.
Info I can see.
$ uname -r
3.11.0-rc7
# rpm -qa| grep samba
samba-libs-4.0.9-1.fc19.i686
samba-common-4.0.9-1.fc19.i686
samba-client-4.0.9-1.fc19.i686
samba-4.0.9-1.fc19.i686
rpm -qa| grep cifs
cifs-utils-6.1-3.fc19.i686
su -
# mkdir /mnt/samba
# mount -t cifs //{IP Address of Windows 7 Machine}c /mnt/samba -o user=raj,password={password},rw,nosetuids,noserverino,noperm,file_mode=0777,vers=2.1
As normal user on linux side.
$ cd /mnt/samba/Users/Resident/Pictures
$ mkdir testdir2
$ scp -v -r -P /run/media/raj/GoflexEXT4/Pictures/* testdir2
It works, but the files have a time/stamp of current date, versus the Linux date.
Regards,
Raj A. Upadhyaya
Last edited by Rupadhya; 08-28-2013 at 06:06 PM.
|