Problem with grub-install

I have 2 partitions on this disk:

sudo fdisk -l

Device Start End Sectors Size Type
/dev/nvme0n1p1 2048 206847 204800 100M EFI System
/dev/nvme0n1p5 307200000 727039999 419840000 200.2G Linux filesystem

  • A partition setup for installing grub bootloader
  • My encryped luks drive

I am using this command:

sudo mount -v /dev/nvme0n1p1 /boot/efi

and i am getting this verbose output:

mount: /dev/nvme0n1p1 mounted on /boot/efi.

After pressing F5 to refresh all partitions KDE Partition manager doesnt see it mounted. (Looks the same as the first screenshot)

When i try to install the bootloader like this:

sudo grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=manjaro --recheck

Installing for x86_64-efi platform.
grub-install: error: /boot/efi doesn’t look like an EFI partition.

Important Information:

  • The luks partition is currently running and mounted at / (i am using it right now)
  • The EFI partition is FAT32 format and 100MB

Why will the folder not mount?

Hi and welcome to the forum :+1:

You actually already mounted it successfully, see the last line of your own quote:

To pinpoint the cause it would help to start with the output of sudo fdisk -x /dev/nvme0n1 or however your HD is named…
Please use 3 backticks on own line, before and after, the output in total.

PS: I’m changing the topic title, because the problem is not mounting as shown above.

Here is the output of that command

sudo fdisk -x /dev/nvme0n1
Disk /dev/nvme0n1: 465.76 GiB, 500107862016 bytes, 976773168 sectors
Disk model: Samsung SSD 970 EVO 500GB               
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: A9A5F747-418D-4E3E-9270-F5FB5B61131A
First LBA: 34
Last LBA: 976773134
Alternative LBA: 976773167
Partition entries LBA: 2
Allocated partition entries: 128

Device             Start       End   Sectors Type-UUID                            UUID                                 Name Attrs
/dev/nvme0n1p1      2048    206847    204800 C12A7328-F81F-11D2-BA4B-00A0C93EC93B E312F571-6D73-4B67-BE8F-254455CB2497      
/dev/nvme0n1p5 307200000 727039999 419840000 0FC63DAF-8483-4772-8E79-3D69D8477DE4 AD8A87D4-62DE-4B24-B9D2-4950A96B261F  

To be able to regain access to my LUKS partition i had to restore the EFI partition i backed up then deleted via the KDE Partition Manager, so now i have 2 EFI partitions on different disks and im not sure if its using the new or old one. I assume the old one. The old EFI partition has a /manjaro and /windows section in it for dual booting.

The underlying problem i am trying to solve is to be able to choose Windows Boot Manager or Manjaro before entering a full disk encryption password because my /boot is inside the LUKS paritition. I am trying to reinstall the bootloader outside of the LUKS partition , but i dont know what im doing.

Here is how my PC boots:

  1. Ask for LUKS password
  2. Choose Manjaro or Windows Boot Manager
  • from there i can boot manjaro or windows

I want to be able to choose Manjaro or Windows before entering a luks password.
I cannot find enough documentation how to move the /boot outside of LUKS.

Do you have any insight how to do this?

I am in progress of creating this 👩‍🏫[HowTo] Boot without a password for encrypted root partition

I will return to your specific issue after that :wink:

Is the efi and boot flag set for your EFI partition? You can check it for example by

sudo parted -l

I have finished that howto i linked above, please read it.
If the info i provided in there is not enough to answer those questions just tell us and we will try to help more.

When it comes to the topic’s title-problem, i see that @Wollie has stepped in to aid you more and i’m sure others will step in as needed…

Disk /dev/nvme0n1: 500GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size   File system  Name  Flags
 1      1049kB  106MB  105MB  fat32              boot, esp
 5      157GB   372GB  215GB


Model: Samsung SSD 970 EVO 500GB (nvme)
Disk /dev/nvme1n1: 500GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size    File system  Name                          Flags
 1      1049kB  556MB  555MB   ntfs         Basic data partition          hidden, diag
 2      556MB   660MB  104MB   fat32
 3      660MB   676MB  16.8MB               Microsoft reserved partition  msftres
 4      676MB   500GB  499GB   ntfs         Basic data partition          msftdata

boot and esp is set, is that what you mean?