Fdupe
Update: December 17th, 2012
Fdupe is a small Perl script which recursively scans directories and finds any duplicate files. It is designed for administrators, who work often on severals machines under different operating systems without a GUI.
Features:
- Single Perl Script, works in environments without GUI
- Efficient algorithm for quick comparing file contents
- No hash checking, thus no hash collisions
- Portable. Needs only /usr/bin/perl to run
Usage Examples
Use fdupe as pipe
# find / -xdev | fdupe.pl |tee dupes.txt
or give some directories as arguments
$ fdupe.pl ./dir1 ./dir2 | tee dupes.txt
Now edit dupes.txt and prepend a ‘-’ for every file you want to delete.
size: 423423 -./dir1/file1 ./dir2/file1
To delete marked files use following script:
#!/usr/bin/perl chomp; unlink if s/^-//;
Example:
$ deldupes dupes.txt
Comments are welcome.




![Balancing On The Edge [Strawberry Cream Splash]](http://farm7.staticflickr.com/6149/5977303079_ea75d9abbc_s.jpg)

