Reflinks
Create multiple references to the underlying file. Initially it doesnât take up any extra space. However, any reflink that is modified becomes a distinct file, via CoW.
Hardlinks
Create multiple references to the underlying file, taking up no extra data. Modifications to any of hardlinks changes the underlying file.
Symlinks
A pointer to some underlying file.
Comparisons
Aspect | Reflink | Hardlink | Symlink |
---|---|---|---|
Use case | Efficient data duplication with CoW | Multiple names for the same file in the filesyst | A shortcut to access the underlying file |
File updates | A new copy of the file is created, resulting in a diverging brancd | The underlying data referenced by all hardlinks is changed | The underlying file is modified |
File deletion | The reflink (âs copy) is deleted, but other reflinks exist as usual. | No effect. Underlying data is deleted only when all hardlinks are deleted | The pointer is left dangling |