Hello Fedora Enthusiasts!
I am looking for self-healing file system for daily use on desktop and laptop as well as for regular backups on external drive.
My goals:
- automatic (on read) or semi-automatic (periodic scans) data corruption detection;
- backups and folder synchronization:
a) easy backups of selected folders from two machines (desktop and laptop) to external drive - in case of the same folders on both computers I want to check file condition and synchronize correct version of files between computers and drive;
b) folder synchronization between two machines (desktop and laptop), preferably byrsync
; - Support for encryption (LUKS?);
- Mechanism for easy file repair (based on full or partial backup - just show the folder with copies and system will pick uncorrupted files and use them to repair files on other drive);
- easy snapshots for more periodic local backups and file versioning (in case of unintended modification of file);
- [nice to have] deduplication to eliminate duplicated data on the same disk;
Originally I decided to give a try to Btrfs for system drive as well as for data storage.
I read the series Working with Btrfs, performed presented hands on exercises, and then read few more articles.
My findings related to Btrfs:
fsck
is not advised for repairing Btrfs filesystem. Better to do a backup using Live CD;btrfs-restore
can be used to recover files without modifying them;- âA consistent set of changes. To avoid generating very large amounts of disk activity, btrfs caches changes in RAM for up to 30 secondsâ - no more than 30 seconds of changes can be lost (or, in other words, up to 30 seconds of data changes might be lost);
- copy-on-write (COW) does not guarantee to access any version of modified state - only the ones from created snapshots (user cannot choose file version from arbitrary time);
- self-healing does not mean corrupted files will be automatically repaired, data corruption is detected on read or on demand (based on stored checksums)! It is stated in official documentation: âSelf-healing - checksums for data and metadata, automatic detection of silent data corruptionsâ;
- Btrfs is tend to cause file system fragmentation;
- in comments under article âChoose between Btrfs and LVM-ext4â as well as on Fedora Discussion I found many reports regarding issues with Btrfs;
- Red Hat Enterprise Linux deprecated Btrfs! âStratis was first released in Red Hat Enterprise Linux 8.0. It is conceived to fill the gap created when Red Hat deprecated Btrfs. (âŠ) Stratis offers powerful features, but currently lacks certain capabilities of other offerings that it might be compared to, such as Btrfs or ZFS. Most notably, it does not support CRCs with self healing.â
- Btrfs can turn into read-only in case of error - it might be extremely problematic on system drive, especially on laptop when not in home!
My findings related to OpenZFS:
- need to be incorporated to Linux kernel manually (not built in);
- ZFS use more memory and is prone to errors in case of malfunctioning RAM;
- unlike BTRFS, ZFS does not support dynamic disk pool expansion (cannot add or remove disks from existing pool without destroying and recreating the pool).
Main questions:
- Btrfs, despite promising, seems to be not mature enough to store important files or use it on system drive. Am I right? Any thoughts?
- I found many positive opinions related to ZFS. Unfortunately, due to its license, OpenZFS is not build in into Linux kernel. It is possible to manually add support for OpenZFS to Fedora. Any known constraints or drawbacks? Can mitigate potential problems if not using ECC RAM?
- bcachefs - reasonable alternative to Btrfs and OpenZFS, or not yet?
- How to set encrypted OpenZFS partition? Will option for LUKS appear when OpenZFS is installed?
Additional questions:
- [Btrfs] How can I repair file(s) based on copies from
a) different drive with Btfrs?;
b) different drive with other file system (eg OpenZFS or ext4)?;
c) different folder (if folder on other drive has different name)?; - [OpenZFS] How can I repair file(s) based on copies from
a) different drive with OpenZFS?;
b) different drive with other file system (eg Btrfs or ext4)?;
c) different folder (if folder on other drive has different name)? - [OpenZFS] Any recommended tools to facilitate work with ZFS on Linux?
Enjoy rest of the day!