Can file modification dates only be transferred from source to dest?
Bo Berglund
bo.berglund at gmail.com
Wed Jan 12 10:07:46 UTC 2022
I have run a big file copy job tonight for about 150 GB worth of files from my
Synology NAS to a new backup file device to be installed at a remote location.
The transfer was done on the command line of the receiving device using an nfs
mount of the source.
So after hours of copy overnight all of the files are now present on the new
device in their original relative positions.
BUT I have screwed up the copy command, I used this:
time cp -rf /mnt/backup/* /mnt/data/nas/
instead of the intended
time cp -rfp /mnt/backup/* /mnt/data/nas/
The result is that the timestamps are all from tonight for *every* file in the
set (a LOT of files).
Question:
Is there some way to run through the files and only transfer the timestamps to
the already existing files? They are byte-by-byte exactly the same as the source
files.
Or do I have to remove the result of the transfer from tonight and run it yet
again with the correct command?
This will lose me a few hours which I prefer not to.
--
Bo Berglund
Developer in Sweden
More information about the ubuntu-users
mailing list