Well, I had a partial success. I went through the steps below and they all seemed to work. But when I booted, I was at the grub command line with nothing to edit. I booted the Kubuntu ISO and went to "Try Kubuntu" and opened a terminal. When I looked at /dev/sdc1 which was my EFI partition, there no boot directory or what should have been in the boot directory after it was mounted on the / file system. I also mounted /dev/sdc3 which was my partition containing the rootfs. There was no @ or @home. There was @old and @homeold, and snapshots. I was also expecting to find @ and @home.
So I took a chance and did
Then I did
and rebooted. I was back to where I was expecting to be. Prior to installing the extra packages.
Here's the sequence of commands I did.
Install some extra stuff
To simulate new drive but same UUIDs, delete old snapshots.
Restore images from external backup to /mnt/snapshots directory
make it read-write and put it at /mnt@ and /mnt/@home
Not sure why grub was not there. Must have something to do with the EFI partition being mounted on /boot which is part of the @ subvolume.
Maybe all of this restore stuff should be done from the Kubuntu install ISO terminal?
So I took a chance and did
Code:
btrfs su sn /mnt/snapshots/@_basic_install /mnt/@ btrfs su sn /mnt/snapshots/@home_basic_install /mnt/@home
Code:
grub-install /dev/sdc1
Here's the sequence of commands I did.
Code:
mount /dev/sdc3 /mnt mkdir /mnt/snapshots mount /dev/sda1 /backup btrfs su snapshot -r /mnt/@ /mnt/snapshots/@_basic_install btrfs su snapshot -r /mnt/@home /mnt/snapshots/@home_basic_install btrfs send /mnt/snapshots/@_basic_install | btrfs receive /backup btrfs send /mnt/snapshots/@home_basic_install | btrfs receive /backup
To simulate new drive but same UUIDs, delete old snapshots.
Code:
btrfs su de /mnt/snapshots/@_basic_install btrfs su de /mnt/snapshots/@home_basic_install
Code:
btrfs send /backup/@_basic_install | btrfs receive /mnt/snapshots/ btrfs send /backup/@home_basic_install | btrfs receive /mnt/snapshots/
Code:
btrfs su sn /mnt/snapshots/@_basic_install /mnt/@ btrfs su sn /mnt/snapshots/@home_basic_install /mnt/@home
Maybe all of this restore stuff should be done from the Kubuntu install ISO terminal?
Comment