I have a problem rsyncing my folders. In my home there is folder named "workspace". Recently I changed its content a lot, creating new directories, deleting old ones. New folders were successfully rsynced to external disk but deleted folders are still on external disk, not deleted. Same if I rsync to my other backup network location. While trying to investigate the reason I tried this two commands:
rsync -nav --delete --exclude='.gvfs' --exclude='.cache' --exclude='.thumbnails' /home/OURDOMAIN/myname/workspace /run/media/myname/VERBATIM/backup/myname > dryrun.txt
and after this dry run the dryrun.txt file contains all the files and folders from workspace folder to be deleted marked with "deleting", that's ok. But i want to run my rsync command for whole home directory, but it's not working. With command:
rsync -nav --delete --exclude='.gvfs' --exclude='.cache' --exclude='.thumbnails' /home/OURDOMAIN/myname /run/media/myname/VERBATIM/backup > dryrun2.txt
Now dryrun2.txt lines marked with "deleting" are only for some recently deleted files in .local and .config. Nothing for workspace directory.
Why is it not working as I expect? New folders are copied, but deleted folders are not deleted. I am not using file masks as you can see. I think problem is not in my exclude dirs. As shown by dry run it is also not a problem of permissions. Thanks for help.
rsync version 3.0.9 protocol version 30
Additional note: If i create some nonempty directories and do rsync, they are copied successfully. When I delete those folder and do rsync, they disappear in backup only if folder is directly in /home/OURDOMAIN/myname (such as /home/OURDOMAIN/myname/deleteme). But nested directories like /home/OURDOMAIN/myname/tmp/deleteme stay with all their content and are not deleted.