Rdfind scans directories and finds duplicate files by comparing content, not filenames. It reports savings and can optionally delete or link duplicates.
Overview
Rdfind is a redundant data finder for disk housekeeping and backup compression. It walks one or more directories or individual files, ranks paths by user-supplied priority, and identifies groups of equal-sized files that match through progressive filters on leading bytes, trailing bytes, and checksums.
The default run writes a results file listing duplicate groups and how much space could be reclaimed. Operators can review paths marked as first occurrence versus later copies, then remove duplicates manually or use flags to delete files, replace them with symbolic links, or collapse them to hard links toward a chosen original.
The implementation sorts by inode where possible to limit disk reads, optional hard-link collapsing treats linked names as one entry, and checksum support can use nettle-backed digests with optional xxhash when available. Package managers on Debian, Ubuntu, Fedora, and Homebrew on Mac distribute binaries; Windows use is described via Cygwin.
Worst-case effort scales on the order of N log N in file count. Published benchmarks in project materials report faster runs than some named peer tools on large photo directories, though environments vary.
Key features
- Content-based duplicate detection
- Configurable path priorities
- Size and checksum filtering stages
- Optional delete or link actions
- Human-readable results file
- Hard-link aware grouping
- Optional xxhash checksums
- Inode-ordered disk access
Use cases
- Shrinking backup directories
- Finding redundant media files
- Auditing duplicate downloads
- Automated deduplication with links