Should openSUSE Leap trigger automatic Btrfs snapshot rollback after a failed unattended update?
0 reputation · 03 Jun 2023, 21:39 UTC
0 reputation · 03 Jun 2023, 21:39 UTC
Our production openSUSE Leap host uses Btrfs subvolumes with Snapper-managed snapshots. After a failed unattended update, we must decide whether the system should roll back automatically or wait for an explicit operator decision.
Snapper restores files only on covered subvolumes. It cannot restore external databases, remote configuration, DNS records, or service state outside those filesystems. Rollback usually reboots the host, so mounts, open connections, and running processes must be re-established and checked. Automatic rollback can repeatedly restore a persistently faulty state and may reintroduce outdated credentials or missing security fixes. Manual rollback preserves judgment but increases recovery time and requires a tested runbook.
What conditions should trigger automatic rollback versus an explicit operator decision? How should the host handle services and external state that Snapper cannot restore? Which checks confirm application-level consistency before returning the host to production?
36775 reputation · 04 Jun 2023, 00:49 UTC
No. A production openSUSE Leap host should not trigger automatic Btrfs snapshot rollback after every failed unattended update. Rollback should remain an explicit operator decision unless a runbook has prequalified it for that specific host class.
zypper and Snapper can create pre- and post-update snapshots, and the bootloader can list snapshot boot entries. Snapper rollback is not an online file restore: it usually reboots the host and changes the default Btrfs subvolume. Open connections, mounts, and running processes are not re-established automatically.
Automatic rollback restores only files on Snapper-covered subvolumes. It cannot restore databases, remote DNS or LDAP records, cloud metadata, secrets, or service runtime state outside those filesystems. Rolling back /etc or application files can reintroduce stale credentials and miss security fixes from the failed update. A repeatedly faulty package can also cause a rollback loop.
Confirm whether /boot, kernel/initramfs, and /etc are on Snapper-covered subvolumes included in the rollback target. This detail changes the recommendation: if they are not covered, rollback cannot restore the bootable system state reliably.
snapper list snapper config get root
After booting into a snapshot, run:
rpm -qa | grep affected-package systemctl status service-name
Assumption: this applies to openSUSE Leap with a standard Snapper configuration, not Tumbleweed or a custom transactional setup. Behavior varies by Leap version, Snapper config, and bootloader plugin; verify the running system before relying on this guidance.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.