Open/Import snapper backup to new installation

inxi -Faz
System:    Kernel: 5.14.9-zen2-1-zen x86_64 bits: 64 compiler: gcc v: 11.1.0 
           parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen root=UUID=a001bc57-d836-4386-9bea-cc69eb7b4804 rw 
           [email protected] quiet splash rd.udev.log_priority=3 vt.global_cursor_default=0 
           systemd.unified_cgroup_hierarchy=1 loglevel=3 
           Desktop: GNOME 40.5 tk: GTK 3.24.30 wm: gnome-shell dm: GDM 40.1 Distro: Garuda Linux base: Arch Linux 
Machine:   Type: Desktop Mobo: ASRock model: AB350M Pro4 serial: <filter> UEFI: American Megatrends v: P5.50 
           date: 12/20/2018 
CPU:       Info: 6-Core model: AMD Ryzen 5 2600 bits: 64 type: MT MCP arch: Zen+ family: 17 (23) model-id: 8 
           stepping: 2 microcode: 800820D cache: L2: 3 MiB 
           flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm bogomips: 81435 
           Speed: 2617 MHz min/max: 1550/3400 MHz boost: enabled Core speeds (MHz): 1: 2617 2: 3727 3: 3164 
           4: 3721 5: 3646 6: 2521 7: 3601 8: 3376 9: 2262 10: 2256 11: 2259 12: 2263 
           Vulnerabilities: Type: itlb_multihit status: Not affected 
           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: Full AMD retpoline, IBPB: conditional, STIBP: disabled, RSB filling 
           Type: srbds status: Not affected 
           Type: tsx_async_abort status: Not affected 
Graphics:  Device-1: NVIDIA GM200 [GeForce GTX 980 Ti] vendor: Gigabyte driver: nvidia v: 470.74 
           alternate: nouveau,nvidia_drm bus-ID: 23:00.0 chip-ID: 10de:17c8 class-ID: 0300 
           Display: x11 server: X.Org 1.20.13 compositor: gnome-shell driver: loaded: nvidia unloaded: modesetting 
           alternate: fbdev,nouveau,nv,vesa display-ID: :1 screens: 1 
           Screen-1: 0 s-res: 4480x1440 s-dpi: 96 s-size: 1185x381mm (46.7x15.0") s-diag: 1245mm (49") 
           Monitor-1: HDMI-0 res: 1920x1080 dpi: 92 size: 530x300mm (20.9x11.8") diag: 609mm (24") 
           Monitor-2: DP-0 res: 2560x1440 dpi: 109 size: 597x336mm (23.5x13.2") diag: 685mm (27") 
           OpenGL: renderer: NVIDIA GeForce GTX 980 Ti/PCIe/SSE2 v: 4.6.0 NVIDIA 470.74 direct render: Yes 
Audio:     Device-1: NVIDIA GM200 High Definition Audio vendor: Gigabyte driver: snd_hda_intel v: kernel 
           bus-ID: 23:00.1 chip-ID: 10de:0fb0 class-ID: 0403 
           Device-2: Advanced Micro Devices [AMD] Family 17h HD Audio vendor: ASRock driver: snd_hda_intel 
           v: kernel bus-ID: 25:00.3 chip-ID: 1022:1457 class-ID: 0403 
           Device-3: GYROCOM C&C Fiio E10 type: USB driver: hid-generic,snd-usb-audio,usbhid bus-ID: 3-1:2 
           chip-ID: 1852:7022 class-ID: 0102 
           Sound Server-1: ALSA v: k5.14.9-zen2-1-zen 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.38 running: yes 
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet vendor: ASRock driver: r8169 v: kernel 
           port: f000 bus-ID: 1f:00.0 chip-ID: 10ec:8168 class-ID: 0200 
           IF: enp31s0 state: up speed: 1000 Mbps duplex: full mac: <filter> 
Bluetooth: Device-1: Cambridge Silicon Radio Bluetooth Dongle (HCI mode) type: USB driver: btusb v: 0.8 
           bus-ID: 1-6:2 chip-ID: 0a12:0001 class-ID: e001 
           Report: bt-adapter ID: hci0 rfk-id: 0 state: up address: <filter> 
Drives:    Local Storage: total: 3.44 TiB used: 837.39 GiB (23.8%) 
           SMART Message: Required tool smartctl not installed. Check --recommends 
           ID-1: /dev/sda maj-min: 8:0 vendor: Seagate model: ST2000DM008-2FR102 size: 1.82 TiB block-size: 
           physical: 4096 B logical: 512 B speed: 6.0 Gb/s type: HDD rpm: 7200 serial: <filter> rev: 0001 
           ID-2: /dev/sdb maj-min: 8:16 vendor: Crucial model: CT275MX300SSD1 size: 256.17 GiB block-size: 
           physical: 512 B logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: R031 scheme: GPT 
           ID-3: /dev/sdc maj-min: 8:32 vendor: Crucial model: CT500MX500SSD4 size: 465.76 GiB block-size: 
           physical: 512 B logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: 023 scheme: GPT 
           ID-4: /dev/sdd maj-min: 8:48 vendor: Seagate model: ST1000DM010-2EP102 size: 931.51 GiB block-size: 
           physical: 4096 B logical: 512 B speed: 6.0 Gb/s type: HDD rpm: 7200 serial: <filter> rev: CC43 
           scheme: GPT 
           ID-5: /dev/sde maj-min: 8:64 type: USB vendor: SanDisk model: Ultra size: 7.45 GiB block-size: 
           physical: 512 B logical: 512 B type: N/A serial: <filter> rev: 1.20 scheme: MBR 
Partition: ID-1: / raw-size: 48.83 GiB size: 48.83 GiB (100.00%) used: 23.55 GiB (48.2%) fs: btrfs dev: /dev/sdc1 
           maj-min: 8:33 
           ID-2: /boot/efi raw-size: 601 MiB size: 599.8 MiB (99.80%) used: 576 KiB (0.1%) fs: vfat dev: /dev/sdc3 
           maj-min: 8:35 
           ID-3: /home raw-size: 416.35 GiB size: 416.35 GiB (100.00%) used: 98.33 GiB (23.6%) fs: btrfs 
           dev: /dev/sdc2 maj-min: 8:34 
           ID-4: /var/log raw-size: 48.83 GiB size: 48.83 GiB (100.00%) used: 23.55 GiB (48.2%) fs: btrfs 
           dev: /dev/sdc1 maj-min: 8:33 
           ID-5: /var/tmp raw-size: 48.83 GiB size: 48.83 GiB (100.00%) used: 23.55 GiB (48.2%) fs: btrfs 
           dev: /dev/sdc1 maj-min: 8:33 
Swap:      Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default) 
           ID-1: swap-1 type: zram size: 31.28 GiB used: 0 KiB (0.0%) priority: 100 dev: /dev/zram0 
Sensors:   System Temperatures: cpu: 44.1 C mobo: N/A gpu: nvidia temp: 36 C 
           Fan Speeds (RPM): N/A gpu: nvidia fan: 37% 
Info:      Processes: 392 Uptime: 26m wakeups: 0 Memory: 31.28 GiB used: 4.69 GiB (15.0%) Init: systemd v: 249 
           tool: systemctl Compilers: gcc: 11.1.0 Packages: pacman: 1090 lib: 288 Shell: fish v: 3.3.1 
           default: Bash v: 5.1.8 running-in: gnome-terminal inxi: 3.3.06

Hello everyone. Today I decided to reinstall the latest version of Garuda Gnome. Rather than manually importing my configs and settings one at a time, I've tried importing my snapper snapshot that i copied to an external drive. The problem is, after i copied it back to the /.snapshots/ directory, the backup still does not show up in garuda assistant. It also does not show up in snapper list in terminal. I've tried searching online on how to import snapper backups with no luck.

My imported backup is called "13" and it is missing below. Here is my output of snapper list:

  # | Type   | Pre # | Date                        | User | Cleanup | Description                                                              | Userdata                                                                   
----+--------+-------+-----------------------------+------+---------+--------------------------------------------------------------------------+----------------------------------------------------------------------------
 0  | single |       |                             | root |         | current                                                                  |                                                                            
 3  | pre    |       | Mon 04 Oct 2021 01:46:11 PM | root | number  | pacman -S a52dec aalib accountsservice acl adobe-source-code-pro-fonts a |                                                                            
 4  | post   |     3 | Mon 04 Oct 2021 01:49:44 PM | root | number  | a52dec aalib accountsservice acl adobe-source-code-pro-fonts adwaita-ico |                                                                            
 5  | pre    |       | Mon 04 Oct 2021 01:53:08 PM | root | number  | pacman --sync -- pavucontrol                                             |                                                                            
 6  | post   |     5 | Mon 04 Oct 2021 01:53:09 PM | root | number  | pavucontrol                                                              |                                                                            
 7  | pre    |       | Mon 04 Oct 2021 01:55:00 PM | root | number  | /usr/bin/pamac-daemon                                                    |                                                                            
 8  | post   |     7 | Mon 04 Oct 2021 01:55:01 PM | root | number  | qt5-charts stacer                                                        |                                                                            
 9  | pre    |       | Mon 04 Oct 2021 01:58:17 PM | root | number  | /usr/bin/pacman --noconfirm --noprogressbar -S linux-lts linux-lts-heade |                                                                            
10  | post   |     9 | Mon 04 Oct 2021 01:58:48 PM | root | number  | linux-lts linux-lts-headers                                              |                                                                            
11  | pre    |       | Mon 04 Oct 2021 02:07:30 PM | root | number  | pacman -Rc systemd-guest-user                                            |                                                                            
12  | post   |    11 | Mon 04 Oct 2021 02:07:32 PM | root | number  | systemd-guest-user                                                       |                                                                            
14  | pre    |       | Mon 04 Oct 2021 02:14:16 PM | root | number  | pacman --sync -- snap-sync                                               |                                                                            
15  | post   |    14 | Mon 04 Oct 2021 02:14:17 PM | root | number  | snap-sync                                                                |                                                                            
16  | single |       | Mon 04 Oct 2021 02:15:16 PM | root |         | latest incremental backup                                                | backupdir=.snapshots, subvolid=5, uuid=69db3f47-b2d3-40ec-bd8b-aad990c98d99
17  | pre    |       | Mon 04 Oct 2021 02:20:17 PM | root | number  | pacman --sync -- neovim                                                  |                                                                            
18  | post   |    17 | Mon 04 Oct 2021 02:20:18 PM | root | number  | libluv libtermkey libvterm luajit msgpack-c neovim tree-sitter unibilium |                                                                            
19  | pre    |       | Mon 04 Oct 2021 02:21:12 PM | root | number  | pacman --sync -- nano                                                    |                                                                            
20  | post   |    19 | Mon 04 Oct 2021 02:21:13 PM | root | number  | nano                                                                     |                                                                            
21  | pre    |       | Mon 04 Oct 2021 02:29:48 PM | root | number  | pacman --sync -- firefox-nightly                                         |                                                                            
22  | post   |    21 | Mon 04 Oct 2021 02:29:49 PM | root | number  | firefox-nightly

proof that folder 13 is in the /.snapshots/ folder:

╭─[email protected] in /.snapshotsπŸ”’ 
╰─λ ls
drwxr-xr-x - root  4 Oct 13:46 ο„• 3
drwxr-xr-x - root  4 Oct 13:51 ο„• 4
drwxr-xr-x - root  4 Oct 13:53 ο„• 5
drwxr-xr-x - root  4 Oct 13:53 ο„• 6
drwxr-xr-x - root  4 Oct 13:55 ο„• 7
drwxr-xr-x - root  4 Oct 13:55 ο„• 8
drwxr-xr-x - root  4 Oct 13:58 ο„• 9
drwxr-xr-x - root  4 Oct 13:58 ο„• 10
drwxr-xr-x - root  4 Oct 14:07 ο„• 11
drwxr-xr-x - root  4 Oct 14:07 ο„• 12
drwxr-xr-x - root  4 Oct 13:57 ο„• 13
drwxr-xr-x - root  4 Oct 14:14 ο„• 14
drwxr-xr-x - root  4 Oct 14:14 ο„• 15
drwxr-xr-x - root  4 Oct 14:16 ο„• 16
drwxr-xr-x - root  4 Oct 14:20 ο„• 17
drwxr-xr-x - root  4 Oct 14:20 ο„• 18
drwxr-xr-x - root  4 Oct 14:21 ο„• 19
drwxr-xr-x - root  4 Oct 14:21 ο„• 20
drwxr-xr-x - root  4 Oct 14:29 ο„• 21
drwxr-xr-x - root  4 Oct 14:29 ο„• 22

Does anyone know a solution? It would be very much appreciated.

1 Like

Can we see the contents of the 13 directory and the output of sudo btrfs subvolume list /

oh i forgot to mention, but it also doesnt show up using that command:

 ╭─[email protected] in ~ via  took 15ms
 ╰─λ sudo btrfs subvolume list /
ID 256 gen 227 top level 5 path @
ID 257 gen 106 top level 5 path @root
ID 258 gen 37 top level 5 path @srv
ID 259 gen 204 top level 5 path @cache
ID 260 gen 225 top level 5 path @log
ID 261 gen 226 top level 5 path @tmp
ID 273 gen 214 top level 256 path .snapshots
ID 306 gen 138 top level 273 path .snapshots/11/snapshot
ID 307 gen 139 top level 273 path .snapshots/12/snapshot
ID 308 gen 151 top level 273 path .snapshots/14/snapshot
ID 309 gen 152 top level 273 path .snapshots/15/snapshot
ID 310 gen 155 top level 273 path .snapshots/16/snapshot
ID 312 gen 166 top level 273 path .snapshots/17/snapshot
ID 313 gen 168 top level 273 path .snapshots/18/snapshot
ID 314 gen 172 top level 273 path .snapshots/19/snapshot
ID 315 gen 173 top level 273 path .snapshots/20/snapshot
ID 316 gen 182 top level 273 path .snapshots/21/snapshot
ID 317 gen 183 top level 273 path .snapshots/22/snapshot

Well, that would be the reason.

How did you move the snapshot between drives?

a simple copy and paste solution during a bootable usb session before installing garuda. My steps:

  1. using garuda welcome, mount previous gnome system using the chroot function in garuda welcome in bootable iso
  2. Old system mounted to /mnt
  3. sudo cp -r /mnt/.snapshots/13 /run/media/external_drive_3

In new system after installation:

  1. su
  2. cp -r /run/media/external_drive_3/13 /.snapshots

That doesn't copy the snapshot. It copies the snapshot contents out of the snapshot. That is why snapper doesn't see the snapshot, it isn't a snapshot anymore.

Also, sudo cp -r probably would break all the permissions so I don't think you can use that for much.

That being said, is there a reason to reinstall and then restore a snapshot? That would remove any benefits of the reinstall even if it did work.

2 Likes

i see, well i guess it was my fault then :sweat_smile:

No reason, just for insurance in case i forget anything. But is there a proper way to backup snapper snapshots to an external and move them back to root for restoration?

You need a btrfs filesystem on both devices and then you can use btrfs send/receive to send the snapshot to other device. Then reverse the operation to put it back. The btrfs devices can be on the same machine or different machines connected by a network.

7 Likes

Thanks, ill look that up. Also can snapper directly backup to the external if i formated it to btrfs?

No, but there are some 3rd party programs that take your local snapper snapshots and replicate them to an external or remote device automatically.

Alright, thanks for your help. Ill try out something like snap-sync and see how it goes.

1 Like

As a side note, the data you have stored in /.snapshots/13 is probably consuming a lot of disk space because it isn't a snapshot.

2 Likes

lol right, i totally forgot... i will banish it from my root directory.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.