Wednesday, November 25, 2015

How to delete large folders with rsync

If you have large folders with large numbers of big files, using rm to delete it completely might cause problems or be relatively slow.
Use this elegant way to remove the whole folder with rsync that is also substantially faster than using rm command.


mkdir empty_folder

rsync -a --delete empty_folder/ folder_to_delete/



No comments:

Post a Comment