3

While reformatting several portable disks with gparted, with disk 5 I made a terrible mistake: I forgot to choose the correct disk, so gparted took the first listed one, which fortunately was not my 1 TB SSD but the 512MiB partition which I believe is the boot partition ( /dev/nvme0n1p1 ). I had a totally default Ubuntu 18.04.2 OS.

I discovered my mistake directly after I applied the partitioning and ext4 formatting and after I closed gparted, when I saw the one I wanted to reformat, my WD My Book was still unaffected. So the current situation is that, since I quickly supplied power and didn't shutdown, everything on my laptop still works, but I am pretty sure once I restart I will be in trouble missing my boot partition, well having no booter anymore.

I hope that fixing in this situation is possible? I have my liveUSB which I used for the Ubuntu install. Could I directly download in my case something like boot-repair and use it to install the boot stuff again? I am not feeling very comfortable here and would highly appreciate some expert help.

Many thanks in advance, Thomas

1 Answer 1

0

First, back up your data (which lives in /home) to one (or more) of those freshly reformatted external USB attached HDDs. Then, verify the data files on the destination match the source files.

Once that's done, you can install Boot-repair in a terminal window and launch it with

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair
4
  • Thanks, I followed that steps, everything goes fine up to boot-repair is running and the little gui pops -up where I selected the "Recommended Repair". Then I get the message: "GPT detected. Please create a BIOS-Boot partition (>1MB, unformatted filesystem, bios_grub flag). This can be performed via tools such as Gparted. Then try again." Commented Jun 28, 2019 at 22:15
  • I tried with gpatred to reformat this 512MiB partition with unformatted instead of ext4. This seems all to go fine including the confirmation messages of gparted, however when closing, I already see in gparted that it did not modify it, it still has the ext4 filesystem even with my previous erroneous label. Indeed boot-repair still gives the same message Commented Jun 28, 2019 at 22:20
  • Thereafter I repeated the step with gparted, but now selecting unformatted and giving the partition a partition name: bios_grub. Running again boot-repair and selecting again "Recommended Repair" I get the message: "The boot of your PC is in EFI mode, but no EFI partition was detected. You may want to retry after creating a EFI partition (FAT32, 100MB~250MB, start of the disk, boot flag). Do you want to continue?" I aborted with NO, being not sure what to decide. Commented Jul 1, 2019 at 7:29
  • I thought this message hints me to repeat once more the step with gparted and reformat this boot partition using the partition name bios_grub now in combination with formatting with the fat32 file system. This time gparted did reformat this boot partition, I have now a fat32 file system for this 512 MiB partition. Running thereafter again boot-repair and selecting again "Recommended Repair" I still get the same message as last time. So I aborted again. Commented Jul 1, 2019 at 7:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .