Computing.Net > Forums > Linux > Directory Time Sync - After copying

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Directory Time Sync - After copying

Reply to Message Icon

Name: Ctrl-G
Date: February 21, 2009 at 19:33:57 Pacific
OS: Ubuntu 8.4 Srvr LTS
CPU/Ram: Via C7-D / 1 Gig
Product: Via / Pc2500
Subcategory: General
Comment:

I have two identical directory trees on two different drives, lets say /mnt/olddrive and /mnt/newdrive. After the VERY long copy operation to get all the files off of the old drive I discovered that I did not preserve the time stamps. I would like to update the time stamps on the new drive with the time stamps of the older files without re-copying .. but am thus far not being successful.

I tried:

cp -dru --preserve=timestamps '/mnt/NwkDrv/Archive/' '/mnt/Addonics1TB/'

That Sort of worked .. but only for directories, not for files.

I even went so far as to write a shell script to touch each file. But it never updates the time stamp.

touch -c --reference=/mnt/NwkDrv/MultMeda/News/2-be056-ada-vid.zip /mnt/Addonics1TB/MultMeda/News/2-be056-ada-vid.zip

The command Executes just fine, produces no error, but the Time and Date on the target never changes.

Any Suggestions?
Bruce



Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Linux Forum Home


Sponsored links

Ads by Google


Results for: Directory Time Sync - After copying

Getting Linux to Time Sync www.computing.net/answers/linux/getting-linux-to-time-sync/11681.html

how to open a file in linux!!!! www.computing.net/answers/linux/how-to-open-a-file-in-linux/14336.html

Decided - I want to install linux.. www.computing.net/answers/linux/decided-i-want-to-install-linux/26301.html