Enable Bcachefs Rollback
Bcachefs is basically quite similar to the Btrfs we know, and if you want to learn more about it, you can read here: Bcachefs Filesystem
Currently, there’s no clear explanation online for how to take snapshots of the / directory system in bcachefs,
so we can now enable snapshots for bcachefs by running the bcachefs-rollback hook of mkinitcpio for initramfs.
Thanks to @bathtime for coming up with this method ❤️
Let’s proceed
Section titled “Let’s proceed”First, we need to git clone this source before proceeding.
cd /tmp/ && git clone https://github.com/RengeOS/Bcachefs-Rollback-InitramfsNext, we will install it by building it from source code with makepkg -si.
cd Bcachefs-Rollback-Initramfs/ && makepkg -siAfter the package build and installation process is successful, our task is to restart the entire system.
# you can replace reboot to 'systemctl reboot' if not workingreboot