Snapper trouble

Hello,

Post your terminal/konsole in- and output as text (no pictures) from:


System:    Kernel: 5.14.15-xanmod1-cacule-1 x86_64 bits: 64 compiler: gcc v: 11.1.0
           parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-xanmod-cacule
           root=UUID=93a7f9be-7906-4efe-9c82-806b2139bd61 rw rootflags=subvol=@ quiet splash
           rd.udev.log_priority=3 vt.global_cursor_default=0 systemd.unified_cgroup_hierarchy=1
           loglevel=3
           Desktop: Xfce 4.16.0 tk: Gtk 3.24.29 info: xfce4-panel, plank wm: xfwm 4.16.1 vt: 7
           dm: LightDM 1.30.0 Distro: Garuda Linux base: Arch Linux
Machine:   Type: Laptop System: HP product: HP ProBook 650 G5 v: N/A serial: <filter> Chassis:
           type: 10 serial: <filter>
           Mobo: HP model: 856E v: KBC Version 54.45.00 serial: <filter> UEFI: HP
           v: R72 Ver. 01.10.01 date: 07/28/2021
Battery:   ID-1: BAT0 charge: 33.8 Wh (96.6%) condition: 35.0/48.0 Wh (72.9%) volts: 11.9
           min: 11.4 model: Hewlett-Packard Primary type: Li-ion serial: <filter> status: Unknown
           cycles: 49
CPU:       Info: Quad Core model: Intel Core i7-8565U bits: 64 type: MT MCP arch: Kaby Lake
           note: check family: 6 model-id: 8E (142) stepping: C (12) microcode: EA cache:
           L2: 8 MiB
           flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 31999
           Speed: 4323 MHz min/max: 400/4600 MHz Core speeds (MHz): 1: 4323 2: 4569 3: 4543
           4: 4494 5: 4499 6: 4499 7: 4598 8: 4506
           Vulnerabilities: Type: itlb_multihit status: KVM: VMX disabled
           Type: l1tf status: Not affected
           Type: mds status: Not affected
           Type: meltdown status: Not affected
           Type: spec_store_bypass
           mitigation: Speculative Store Bypass disabled via prctl and seccomp
           Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer sanitization
           Type: spectre_v2 mitigation: Enhanced IBRS, IBPB: conditional, RSB filling
           Type: srbds mitigation: TSX disabled
           Type: tsx_async_abort status: Not affected
Graphics:  Device-1: Intel WhiskeyLake-U GT2 [UHD Graphics 620] vendor: Hewlett-Packard
           driver: i915 v: kernel bus-ID: 00:02.0 chip-ID: 8086:3ea0 class-ID: 0300
           Device-2: Quanta HP HD Camera type: USB driver: uvcvideo bus-ID: 1-9:5
           chip-ID: 0408:5373 class-ID: 0e02 serial: <filter>
           Display: x11 server: X.Org 1.20.13 compositor: xfwm4 v: 4.16.1 driver: loaded: intel
           unloaded: modesetting alternate: fbdev,vesa display-ID: :0.0 screens: 1
           Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.0x11.2")
           s-diag: 582mm (22.9")
           Monitor-1: eDP1 res: 1920x1080 hz: 60 dpi: 143 size: 340x190mm (13.4x7.5")
           diag: 389mm (15.3")
           OpenGL: renderer: Mesa Intel UHD Graphics 620 (WHL GT2) v: 4.6 Mesa 21.2.4
           direct render: Yes
Audio:     Device-1: Intel Cannon Point-LP High Definition Audio vendor: Hewlett-Packard
           driver: snd_hda_intel v: kernel alternate: snd_sof_pci_intel_cnl bus-ID: 00:1f.3
           chip-ID: 8086:9dc8 class-ID: 0403
           Device-2: HP USB Audio type: USB driver: hid-generic,snd-usb-audio,usbhid
           bus-ID: 1-5.3.5:10 chip-ID: 03f0:0269 class-ID: 0300 serial: <filter>
           Sound Server-1: ALSA v: k5.14.15-xanmod1-cacule-1 running: yes
           Sound Server-2: JACK v: 1.9.19 running: no
           Sound Server-3: PulseAudio v: 15.0 running: no
           Sound Server-4: PipeWire v: 0.3.39 running: yes
Network:   Device-1: Intel Ethernet I219-V vendor: Hewlett-Packard driver: e1000e v: kernel
           port: N/A bus-ID: 00:1f.6 chip-ID: 8086:13be class-ID: 0200
           IF: enp0s31f6 state: down mac: <filter>
           Device-2: Intel Wi-Fi 6 AX200 driver: iwlwifi v: kernel bus-ID: 01:00.0
           chip-ID: 8086:2723 class-ID: 0280
           IF: wlp1s0 state: up mac: <filter>
           Device-3: Realtek RTL8153 Gigabit Ethernet Adapter type: USB driver: r8152
           bus-ID: 2-5.3.3:4 chip-ID: 0bda:8153 class-ID: 0000 serial: <filter>
           IF: enp0s20f0u5u3u3 state: up speed: 1000 Mbps duplex: full mac: <filter>
           IF-ID-1: virbr0 state: down mac: <filter>
           IF-ID-2: wwp0s20f0u3 state: down mac: <filter>
Bluetooth: Device-1: Intel AX200 Bluetooth type: USB driver: btusb v: 0.8 bus-ID: 1-10:7
           chip-ID: 8087:0029 class-ID: e001
           Report: bt-adapter ID: hci0 rfk-id: 0 state: down bt-service: enabled,running
           rfk-block: hardware: no software: yes address: <filter>
Drives:    Local Storage: total: 476.94 GiB used: 72.88 GiB (15.3%)
           SMART Message: Required tool smartctl not installed. Check --recommends
           ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung
           size: 476.94 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s lanes: 4
           type: SSD serial: <filter> rev: EDA76H1Q temp: 31.9 C scheme: GPT
Partition: ID-1: / raw-size: 238.14 GiB size: 238.14 GiB (100.00%) used: 72.81 GiB (30.6%)
           fs: btrfs dev: /dev/nvme0n1p4 maj-min: 259:4
           ID-2: /boot/efi raw-size: 100 MiB size: 96 MiB (96.00%) used: 68 MiB (70.9%) fs: vfat
           dev: /dev/nvme0n1p1 maj-min: 259:1
           ID-3: /home raw-size: 238.14 GiB size: 238.14 GiB (100.00%) used: 72.81 GiB (30.6%)
           fs: btrfs dev: /dev/nvme0n1p4 maj-min: 259:4
           ID-4: /var/log raw-size: 238.14 GiB size: 238.14 GiB (100.00%) used: 72.81 GiB (30.6%)
           fs: btrfs dev: /dev/nvme0n1p4 maj-min: 259:4
           ID-5: /var/tmp raw-size: 238.14 GiB size: 238.14 GiB (100.00%) used: 72.81 GiB (30.6%)
           fs: btrfs dev: /dev/nvme0n1p4 maj-min: 259:4
Swap:      Kernel: swappiness: 133 (default 60) cache-pressure: 50 (default 100)
           ID-1: swap-1 type: zram size: 15.42 GiB used: 0 KiB (0.0%) priority: 100
           dev: /dev/zram0
Sensors:   System Temperatures: cpu: 44.0 C mobo: 0.0 C
           Fan Speeds (RPM): N/A
Info:      Processes: 315 Uptime: 11m wakeups: 1 Memory: 15.42 GiB used: 3.14 GiB (20.3%)
           Init: systemd v: 249 tool: systemctl Compilers: gcc: 11.1.0 clang: 12.0.1
           Packages: 1678 pacman: 1655 lib: 382 flatpak: 15 snap: 8
           Client: Unknown Client: garuda-assistant inxi: 3.3.08

The last days I had a stupid situation with my snapper-snapshots.

Background info:
I follow the garuda linux news closely and was reading, that garuda switches now to snapper as the main snapshot-tool. So, on my system was Timeshift, but it got replaced by Snapper using the "snapper-support" package.

A few days ago I was reading in the "Linux CacULE (feedback & testing)" thread in the forums.
Here was claimed, that you can use a repo to try out new kernels:
https://forum.garudalinux.org/t/linux-cacule-feedback-testing/7672/197

Since snapper was on my system and I wanted to try out those kernels I manually made a snapshot and started the script contained in the github repo to activate the "correct" repos.

What I didn't knew was, that the script did way more than first was claimed and changed my garuda linux to the CachyOS. (Whatever that is about.)

So, I thought "good that there is a snapshot" and wanted to roll back. It didn't work using the garuda assistent, since the "@ / root" was mounted. (With Timeshift that worked!)

When I rebooted and tried to boot with grub in one of the snapshots, that didn't work.
The system bugged in a blackscreen without any chance to recover it. I tried most of the ~10 existing snapshots made with snapper (with multiple kernel choices) but none worked. (That also worked previously with Timeshift.)

I had to create a USB-Stick and boot in a live environment. Mount there the root "/" and was then able to roll back using the garuda assistent. (phew. -> When something breaks in a moment you don't have a USB-Stick you have a problem.)

Why couldn't I boot in my snapshots of snapper? Do I have something misconfigured or is that normal? I couldn't find anything in the wiki.

(-> Otherwise I might not use snapper anymore. It feels broken the moment one can't use its main functionality. Especially when Timeshift worked flawlessly.)

1 Like

This is like my worst nightmare. I love Timeshift so much, saved me gobs of times with successful system restores. Has Snapper been thoroughly tested re actual system backups? :man_shrugging:

In truth, I have never tried to do this so it is possible it does work, I put that check in because it seemed like swapping out the running volume was a bad idea.

I don’t know what is causing this exactly but it probably isn’t snapper. It is just taking snapshots the same way timeshift does. btrfs doesn’t have a lot of options here. You either take a snapshot of the subvolume or you don’t.

I and others tested it fairly extensively but I can’t guarantee some case wasn’t missed.

5 Likes

Hey, thank you for the quick reply tho. I really liked that ability to go back “while running”.

I don’t know what is causing this exactly but it probably isn’t snapper. It is just taking snapshots the same way timeshift does. btrfs doesn’t have a lot of options here. You either take a snapshot of the subvolume or you don’t.

You have a point there. I just want to be sure, that I can “go back” easily. I will check with Timeshift and see if that still works. (If I can boot in a snapshot).

Of cause it can be something with my system. I’ll let you know soon.

There actually is one difference. snapper snapshots are read-only. You can pretty easily convert a snapshot to read-write if you want to test that.

1 Like

Okay, I deleted now all my snapper-snapshots. And installed "timeshift-support".
-> immediately created a snapshot with it.

Then I made a

sudo update-grub && sudo grub-install

Afterwards, I placed a textfile on my desktop. And rebooted.
While booting in grub i chose the latest available snapshot (made with Timeshift).
And a few seconds later I was on my desktop (without the document. So it is in fact the snapshot.)

At this point I don't know what causes that issue with "Snapper-snapshot booting". I don't really know how to debug here deeper.

But I guess I stay with Timeshift for the time being. :wink:

2 Likes

small question, I installes snapper-suport but now I don't know how to limit the number of snapshots, on timeshift it was set to 9 and I could see that when the 10th snaptshot was taken the oldest was deleted, on snapper not so much I have currently 12 snapshots even when the snapper settings tab pacman says 10, how can I limit the number of snapshots?

1 Like

Can you a screenshot of the snapper settings tab so we can see your settings?

sure here it is

I had to check the 'Enable timeline snapshot' and then set up my own schedule, finish with hitting 'Save Config.' That is how I did it to limit when/how many snapshots.

2 Likes

but I dont want to set snapshots by time... will try setting everything to 0 and check

I didn't either, so I only used Pacman, which creates them before you do updates.

2 Likes

You can leave that checkbox disabled then. However, if you took some snapper timeline snapshots before you disabled it those snapshots might still be out there.

Also, you need to ensure that the snapper-cleanup timer is enabled.

3 Likes

This is a complicated order. I have checked, or at least I think I did using;

systemctl list-unit-files --state=enabled

And I don’t see any snapper of any sort listed, nor enabled. Is this the correct way to tell?

The wiki states to make sure you re not running two snapper services at the same time or it can cause issues, and I think it recommends not to use the Pacman option in the scheduler if enabling a timer, which…bites. This all makes me want to go running back to the comfy arms of Timeshift.

systemctl list-timers

I am not sure what you are referring to here but you can certainly enable both timeline snapshots and pac-snap snapshots at the same time.

What you shouldn’t do is use both a cron and the timers together. If you are running a cron, that is all you need. If not, use the timers. They both do the same thing so if you run both you will get duplicate timeline snapshots.

2 Likes

Ahhhh...there we go.

I have both of the following enabled; snapper-boot.service and snapper-timeline.service, assuming the 'timeline' service is handling the clean up crew?

snapper-boot.timer takes snapshots at every boot. snapper-timeline.timer takes snapshots according to your timeline settings(assuming you have that enabled. If it disabled, it does nothing). snapper-cleanup.timer is what removes snapshots that are over your limits. If you don't have the cleanup timer enabled and you don't a metric ton of snapshots, you are probably running a cron.

1 Like

Then this is my homework assignment, because I don’t see that listed. thx. I am also adding to my holiday wishlist simple on/off switches in the GUI for these options. I am been a good boy.

Thanks @dalto , you are awesome as usual.

1 Like

They are on the btrfs tab in garuda asssistant. :wink:

1 Like

WHAT!?! You could have lead with that. :rofl: :joy: OMG, thanks. I totally missed that. I need a new pair of :eyeglasses:…revising wishlist now.

2 Likes