How to efficiently copy only modified files from a disk to external usb?
You're sort of describing what rsync
was designed for. From man rsync
:
Rsync finds files that need to be transferred using a "quick
check" algorithm (by default) that looks for files that have
changed in size or in last-modified time. Any changes in the
other preserved attributes (as requested by options) are made on
the destination file directly when the quick check indicates
that the file’s data does not need to be updated.
There's also a lot of guff about networking, but it's happy doing local too.
Essentially all you need is:
rsync -rtv /home/my_projects_linux /mounted_drive/my_projects_linux
There are a ton of options available but -rtv
will sync recursively, keeping the timecodes the same, while being verbose about what it's doing.