2

I just did a fresh install of Ubuntu 24.04 LTS on BTRFS. Installed Timeshift and it did not work because the 24.04 system was installed on / without creating BTRFS subvolumes @ and @home. (Ubuntu 22.04 installs the system inside @, not /.)

How can we make Timeshift work with the Ubuntu 24.04 install?

Majal
  • 8,249

1 Answers1

3

Thanks to the comments, for it gave me the general idea on how to proceed, as well as this Ubuntu article on reinstalling GRUB 2. The steps below worked on my system, a clean install of Ubuntu 24.04. Edit based on your custom setup. If you have files you can't lose, backup first.

  1. Prepare another system to boot from (e.g. a Live USB). Or attach your system storage to another computer.
  2. Once your system storage is attached, get its device paths, both the system disk and partition.
    Example HDD paths: disk: /dev/sdb, partition: /dev/sdb2
    Example NVME paths: disk: /dev/nvme0n1, partition: /dev/nvme0n1p3
    These paths may be known by running lsblk or fdisk -l if using the CLI, or by launching GNOME Disks if you prefer a GUI.
  3. On the Terminal, run these commands (lines after # are comments):
sudo su

mount /dev/${partition} /mnt cd /mnt

If you haven't yet, edit fstab, i.e. nano /mnt/etc/fstab. The updated fstab must point

from @ or @home subvolumes, so change the options from "defaults" to include "subvol="

Example root: UUID=ABC… / btrfs subvol=@ 0 0

Example home: UUID=ABC… /home btrfs subvol=@home 0 0

btrfs subvolume create @ btrfs subvolume create @home

mv home/* @home mv !(@|@home) @

sync

Mount /boot and /boot/efi if those came from other partitions.

In 24.04 by default, /boot/efi is in another partition, while /boot is not.

To confirm, check fstab, or run ls @/boot/ and it will list several files

If /boot is from another partition, run: mount /dev/${boot_partition} @/boot

mount /dev/${boot-efi_partition} @/boot/efi

https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal

Note: Insert path for system disk, not system partition. See step 2.

grub-install --boot-directory=/mnt/@/boot --efi-directory=/mnt/@/boot/efi /dev/${disk}

Before exiting, double-check that all in @/etc/fstab are in place

  1. Exit Live USB and boot in your system.
Majal
  • 8,249