There are many many solutions to deduplicate files, some of them are listed here . A working an intuitive solution is fdupes , avaliable in default repositories of ubuntu: fdupes -r -d -N -r recursive search -d delete duplicates, preserve first -N silent confirm questions