Skip to content

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 ❤️


First, we need to git clone this source before proceeding.

Terminal window
cd /tmp/ && git clone https://github.com/RengeOS/Bcachefs-Rollback-Initramfs

Next, we will install it by building it from source code with makepkg -si.

Terminal window
cd Bcachefs-Rollback-Initramfs/ && makepkg -si

After the package build and installation process is successful, our task is to restart the entire system.

Terminal window
# you can replace reboot to 'systemctl reboot' if not working
reboot