I have a backup disk which contains hundreds of backups of the same machine from different dates. The backup was made with rsync and hardlinks, i.e. if a file doesn't change the backup script just makes a hardlink to the file in an older backup. So if a file never changes you have essentially one copy in the backup disk but say 100 hardlinks to it in each directory representing the backup of each date (say
back-n). If I want to thin it out, I delete a subset of them but not all. Suppose I want to delete
back_10 (just as an example, in my real szenario there are many more). Then I try to parallize it via:
echo back_5 back_6 back_10 | xargs -n 1 -P 0 rm -rf
This takes multiple hours. So is there any faster way to do this?