Score:0

order of restoring partitions with gnome disk utility

kr flag

I have a 240GB SDD that has failed. But I did backup all the individual partitions with gnome disk utility. Unfortunately, I did not do a "disk image" with gnome disk. I only have images of each partition.

202306030934_Filesystem_Partition5_240GBExt4.img       239.5 GB (file system)
202306030934_exdtendedPartition_Partition2_240GB.img   1KB      (extended partition)
202306030934_Filesystem_Partition1_537MBFAT.img        536.9MB  (MBR)

So I have the same PC all set up with a new SSD (exact same model) And I can boot into the Ubunto 20.04 live USB (same OS version as the partition backups) What is the proper procedure to use gnome disk utility to restore the partitions to the new SSD? Specifically, in what order do I need to restore the partitions? For example: Do I need to restore the MBR first, so it gets put at the front of the new disk? Then the main file partition, then the extended partition?

PonJar avatar
in flag
I’d try MBR first, then extended partition then, the main partition. I don’t know if gnome disks will restore the extended partition correctly, it’s a container for the main partition. Since you have these backups you are in a strong position to try it and if it doesn’t work try a different order. You might find you don’t need the extended “partition” at all.
Score:0
kr flag

Tools used: gnome disk and GParted.

I used gnome-disk to format the new SSD (exact same model as the one that failed). Since the failed disk was MBR, I formatted the new disk with MBR too (as opposed to GPT).

I didn't know this but you can't just restore a partition image to disk. You have to create a partition and restore the image to an existing partition.

I used gnome-disk to create new partitions that were the exact same size (to the byte) as the file size of the image being restored:

202306030934_Filesystem_Partition5_240GBExt4.img 239.5 GB (file system) 202306030934_exdtendedPartition_Partition2_240GB.img 1KB (extended partition) 202306030934_Filesystem_Partition1_537MBFAT.img 536.9MB (MBR)

You can right-click -->Properties for each image file to get size in bytes. Or I'm sure someone knows a switch to change the units of the ls output. In gnome-disk, when you make the new partitions, you can change the size unit to bytes and manually enter the partition size so it's an exact match to the size of the image.

Starting with the MBR, I used gnome-disk to create a partition of the same size. Then I used gnome-disk to restore the saved partition image from the old failed disk to the new partition I just created.

At first, I just restored the MBR and the file system. Nothing happened on reboot so I thought I needed to restore the extended partition, too. But that got me "overlapping partition" errors in GParted.

Then I realized I needed to use gparted to make the MBR bootable. Still, nothing happened. I had to boot from a live CD, chroot to the new disk, and re-install GRUB to the new drive.

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

and now the new drive boots and works perfectly.

So it looks like as the drive was failing, GRUB (and nothing else) got wiped out (probably on start-up).

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.