Snapshots
Appearance
Fiordland installs on Btrfs and takes automatic snapshots with snapper. A snapshot is a frozen copy of the system (not your home folder) at a point in time.
When snapshots are taken
- Before and after every package install, removal or update (snap-pac).
- Every hour, kept as: 5 hourly, 7 daily, 2 weekly, 1 monthly.
List them:
snapper -c root list
Undo a change while the system still boots
Find the "pre" snapshot number from before the bad update, then:
sudo snapper -c root undochange PRE..POST
Reboot afterwards.
Roll back when the system does not boot
Booting straight into a snapshot from the boot menu is not supported yet. This is planned for Fiordland 1. Until then, use the steps below.
First try the other boot entries: Arch kernel and safe graphics. If neither works:
- Boot the Fiordland USB stick and open a terminal.
- Find your Fiordland partition:
lsblk -f(the Btrfs one, for example/dev/nvme0n1p2). - Mount the top of the filesystem:
sudo mount -o subvolid=5 /dev/nvme0n1p2 /mnt
- Pick a snapshot:
sudo ls /mnt/@snapshotsand checksudo cat /mnt/@snapshots/N/info.xmlfor its date. - Move the broken system aside and restore the snapshot:
sudo mv /mnt/@ /mnt/@brokensudo btrfs subvolume snapshot /mnt/@snapshots/N/snapshot /mnt/@
sudo umount /mntand reboot.- Once everything works, delete the old copy:
sudo btrfs subvolume delete /@brokenafter mounting withsubvolid=5again.
The kernel files live on the separate boot partition. If the problem came from a kernel update, reinstall the kernel after rolling back: sudo pacman -S linux-cachyos linux.