1

Following this answer on how to reinstall ubuntu without loosing data when the reinstall ubuntu option is not directly available, when selecting Something else, it asks to select the Device for boot loader installation. The options are:

  • /dev/nvme0n1 the whole disk,
  • /dev/nvme0n1p1, with filesystem fat32 /dev/nvme0n1p11, with filesystemext2`.

/dev/sda is the ubuntu live installation media.

Which partition should be selected?

Here an image:

EDIT The disk is encrypted and booting is corrupted, i.e., it does not boot anymore. Autoselection for boot selection seems to be nvme0n1 but when I click on Install Now, a window appears saying: `No root file system is defined. Please correct this from the partition menu.

enter image description here

Francesco Boi
  • 291
  • 4
  • 17
  • 1
    Does it really ask to select the device, or does it auto-selects, but provides other options as well? – mikewhatever Aug 02 '19 at 17:03
  • 1
    Please see the edit. Autoselection seems to be `nvme0n1` but when I do it a window appears saying: `No root file system is defined. Please correct this from the partition menu. Further note I forgot: the disk was encrypted. – Francesco Boi Aug 02 '19 at 17:05
  • What exactly is your question? – mikewhatever Aug 02 '19 at 17:11
  • 1
    How to identify the partition to be selected? – Francesco Boi Aug 02 '19 at 17:12
  • 3
    With UEFI it does not matter what you select. It automatically installs boot loader into first drive's ESP - efi system partition. Whether UEFI or BIOS you almost always select drive, never partition. If / (root) device not selected, have you decrypted your install, so it can see /? And if separate /boot partition, you must also select it. If issue is just not booting, may be better to resolve that with Boot-Repair or fsck on ext4 partition(s). You do have good backups? If you select format, it will erase old install. – oldfred Aug 02 '19 at 17:36
  • 1
    As implied above, there is not need to select where to install grub, unless there are reasons for that. You should worry about decrypting the root partition, and then designating it as such to the installer. – mikewhatever Aug 02 '19 at 17:36
  • 1
    @oldfred for the backup, I managed to decrypt the disk and copy all my home folder which seems to be intact. After decrypting the disk many selections for `Device for boot loader installation` are available: `/dev/mapper/luks...`, `/dev/mapper/ubuntu--vg-root-root`, `/dev/nvme0n1`, `/dev/nvme0n1p1`, `/dev/nvme0n1p2`, `/dev/dm-0`. I do not have `/` as option though – Francesco Boi Aug 02 '19 at 17:51
  • Although, may I suggest you tape a small note inside battery compartment or on the back of the desktop chassis which states where the boot loader is placed? If you have problems later, it's handy to know. – K7AAY Aug 02 '19 at 17:51
  • 1
    @K7AAY Well, with the wisdom of hindsight, yes you can :) – Francesco Boi Aug 02 '19 at 17:56
  • 2
    Your screen shot above showed an ESP as p1 FAT32, a typical /boot as ext2 formatted as p2 and p3 as the entire install using LVM - logical volumes. – oldfred Aug 03 '19 at 00:08

1 Answers1

1

/dev/nvme0n1p1 is the UEFI system partition, so:

  1. ensure legacy is turned off in the UEFI firmware
  2. Do not encrypt that partition
  3. install the boot loader there
Fabby
  • 34,341
  • 38
  • 97
  • 191