1

I am trying to use rsync (on Linux Mint) to backup to an external USB drive of type msdos (as shown in the drive properties), using a command:

rsync -av ~/Documents/rsynctest/ /media/myname/PC/rsynctest --delete

However it is copying some files that have not been changed since I last run this command. What is going on here and is there a straight forward solution, without having to reformat the drive?

Adding the "i" flag causes the outputs of lines such as:

.f...p..... CBCTest/bin/Debug/CBCTest
4
  • 1
    were the files changes very recently, as-in 1 or 2 seconds?
    – virullius
    Commented Aug 23, 2018 at 19:28
  • No, not recently changed.
    – gornvix
    Commented Aug 23, 2018 at 19:41
  • 1
    Try adding the -i flag. You'll get output with flags for every file it's copying. Can you add in some of the lines that it prints to your question?
    – BowlOfRed
    Commented Aug 23, 2018 at 19:56
  • I updated my question.
    – gornvix
    Commented Aug 23, 2018 at 20:02

3 Answers 3

1

You will need to workaround rsync with:

--size-only

But if the files are exactly the same size but differents, maybe it will be not upgraded.

Good Lucky!

1

Vfat filesystems (that I guess "type msdos" means) does not support user/group/permissions on files, so every file on an vfat filesystem will appear with some synthetic values (set at mount time) for the parameters. If those differ from the values that the files you're trying to sync has, rsync (called with -o/-g/-p - all are included in the meaning of -a) will think something has changed and re-copy the file.

1

In your output

.f...p..... CBCTest/bin/Debug/CBCTest

The "p" means that it is updating the (p)ermissions of the destination file because it thinks they need to be.

(It's not actually copying the file since it's already in place, just updating the permissions).

Some filesystems may simply be incapable of matching the "correct" permissions. For instance if you are trying to rsync to a FAT filesystem that won't store permissions the same way. In such case you may just want to turn off permissions preservation. Either don't supply -p/--perms, or if they're being included through something like -a, give a --no-perms afterward.

Or, maybe the permissions really were changed. You'll have to investigate on your end.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .