By default, the Debian installer names the root subvolume @rootfs. However, Timeshift has a hardcoded requirement looking exclusively for a subvolume named @ (and optionally @home). The core post installation hack was proposed by Google AI Assistant. I've added just one command to second part related with creating @home. The most important step is "The GRUB Edit Route"
Log into your Debian 14 VM normally and rename the subvolumes from underneath the running system.
# Mount the root Btrfs layout to a temporary folder
$ sudo mkdir /tmp/btrfs
$ sudo mount -o subvolid=5 /dev/vda3 /tmp/btrfs (system with /boot on vda2)
# Rename the subvolume
$ sudo mv /tmp/btrfs/@rootfs /tmp/btrfs/@
# Update your fstab immediately so the system knows the new path
$ sudo nano /etc/fstab
# Change "subvol=@rootfs" to "subvol=@" -> Save and exit.
# UPDATE /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="quiet rootflags=subvol=@"
$ sudo update-grub
If your system layout has /var (XFS) and /home (XFS) mounted on separate LVMs belong to VG group say debianVGS . You may reboot in Debian forky an install timeshift via `sudo apt install timeshift` and start Timeshift GUI:
$ sudo timeshift-gtk
If your prefer to keep /home folder under "/" you will be forced to create subvolume @home and mount it as well
# Move the current folder out of the way
$ sudo mv /home /home_backup
# 1. Mount the top-level root pool (ID 5) of your Btrfs drive
$ sudo mkdir /tmp/btrfs_pool
$ sudo mount -o subvolid=5 /dev/vda3 /tmp/btrfs_pool
# 2. Create the exact @home subvolume that Timeshift requires
$ sudo btrfs subvolume create /tmp/btrfs_pool/@home
# 3. Clean up the temporary mount point
$ sudo umount /tmp/btrfs_pool
UPDATE /etc/fstab
UUID=your-vda3-btrfs-uuid /home btrfs defaults,subvol=@home 0 0
# Mount the new subvolume via fstab
$ sudo mkdir /home
$ sudo mount /home
# Move your user data back into the newly mounted subvolume space
$ sudo mv /home_backup/* /home/
# Remove the temporary backup folder
$ sudo rmdir /home_backup
In this case `lsblk -f` would be the following
boris@debianServer:~$ lsblk -f
NAME FSTYPE FSVER LABEL UUID FSAVAIL FSUSE% MOUNTPOINTS
sr0
vda
├─vda1 vfat FAT32 58CD-C1FE 68.6M 12% /boot/efi
├─vda2 ext4 1.0 119959dd-f1b2-493c-9964-58eeb7e318e5 1.6G 6% /boot
├─vda3 btrfs 590ce0cb-91da-4cd1-bb2c-1964e87765bb 65.2G 8% /home
│ /
└─vda4 LVM2_member LVM2 001 uZtjyt-T4dM-2nf5-NW4n-wBAL-0iOf-3lir1Y
└─debianVGT-vol01 xfs db513736-ebef-436a-871a-8a3d7b556900 45.1G 3% /var
In case when /var (xfs) and /home (xfs) are mounted on separate LVMs creating subvolume @home is not your concern only @rootfs should be changed to @ ( code above first snapshot )
boris@debian14VM:~$ lsblk -f
NAME FSTYPE FSVER LABEL UUID FSAVAIL FSUSE% MOUNTPOINTS
sr0
vda
├─vda1 vfat FAT32 3577-8495 68.6M 12% /boot/efi
├─vda2 ext4 1.0 d3dd2332-1f6f-4c40-9273-c2c5d6b9f41a 1.6G 6% /boot
├─vda3 btrfs 2658de53-7273-4133-9a18-a140bf872a9b 46.2G 12% /
└─vda4 LVM2_member LVM2 001 TDj8QE-QtAa-Kfxl-WWxB-aXVE-yVLs-UARNr4
├─DebianVG-VOL01 xfs df364b9e-281a-4edb-b2d0-0be1f6b909f8 49.9G 11% /var
└─DebianVG-VOL02 xfs aacb7d6e-dd1a-4ddf-8177-ccdc0017618b 25.6G 8% /home
For disk layout without /boot (ext4) folder hackery code would be a bit more complicated
In the last case "/" btrfs folder would be mounted on /dev/vda2 rather then /dev/vda3



No comments:
Post a Comment