====== EXT4 ======
====== Fragmentation viewers ======
* [[https://github.com/i-rinat/fragview]]
* [[http://davtools.sourceforge.net/#screenshot]]
====== deduplication ======
Not supported. Duplicated files can be removed and hardlinkied using 3rd party software:
* rdfind is a program to find duplicate files and optionally list, delete them or replace them with symlinks or hard links;
* jdupes - can convert duplicate files in hardlinks or relative softlinks
* fslint - GUI tool (deprecated)
* [[https://snapcraft.io/install/fslint-unofficial/debian|fslint-unofficial]] - snap provided but doesn't work!
* rmlint
* Nice feature to save state: [[https://rmlint.readthedocs.io/en/master/tutorial.html#replaying-results|replaying]]
* Can save checksums to xattr for faster consecutive runs [[https://rmlint.readthedocs.io/en/master/tutorial.html#miscellaneous-options|miscellaneous-options]]
Not for ext4:
* duperemove
===== rmlint =====
rmlint /BIG/POOL --progress --xattr -c sh:hardlink --size 1M
Tools doesn't touch filesystem. It generate ''rmlint.sh'' to make desired modification.
Please review script, especially function ''cp_hardlink''.
Function needs to hande errors a bit better - it first removes file without backup, and then if error occurs during hardlink there is no way back.
1c1
< #!/bin/sh
---
> #!/bin/sh -eu
192a193
> mv "$1" ~"$1".rmlint.$$
194a196
> rm ~"$1".rmlint.$$
===== rdfind =====
rdfind . -dryrun