You are not logged in.

#1 2024-02-17 13:13:10

Gonda
Member
Registered: 2023-09-07
Posts: 8

Is it best practice to put grub on /efi?

I have a multiboot setup with Windows, Debian and Arch. I don't like having my grub config files on my arch directory if I may want to edit them from other OS, or dare I say, switch primary OSs. Putting them an %efi%/grub would resolve this issue. Although I can't read write the efi partition without logging into root which is just as annoying (not sure I want to change user permissions). I suppose reinstalling grub from another OS and just copying over the grub.cfg shouldn't be the issue either...

Do any of you have the grub files on the EFI partition?

Edit: unclear language

Last edited by Gonda (2024-02-20 12:18:04)

Offline

#2 2024-02-17 15:35:26

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 4,097

Re: Is it best practice to put grub on /efi?

XBOOTLDR would be the best option, sadly most distroes doesn't support it out of the box (or at all).

Other than that: IMO let debian handle grub and then just add an entry for arch to its configuration.


Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#3 2024-02-17 18:51:55

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,231

Re: Is it best practice to put grub on /efi?

The mount point in your system does in and of itself not matter at all. There's a logical distinction between mounting the ESP to /boot but that's not because the mount point is special but because kernel files get written to /boot by default.

So I'm not sure what you are actually asking. I install GRUB on "/efi" because I want it to access my kernel files directly on the root partition. If you want to share with debians GRUB anyway, you could just configure debian to load Arch's kernels and not explicitly install GRUB on Arch at all (though Arch's kernel recently dropped a compatibility option that might break older GRUBs so pending on what you have on your debian it might make sense to explicitly install Arch's GRUB as well).  But again the  mount point you operate GRUB with does not matter, as long as you aren't masking /boot

Offline

#4 2024-02-17 19:05:30

woistmeinauto
Member
Registered: 2020-03-18
Posts: 4

Re: Is it best practice to put grub on /efi?

Mr.Elendig wrote:

XBOOTLDR would be the best option, sadly most distroes doesn't support it out of the box (or at all).

I don't like keeping any part of the bootloader out of the EFI partition. The EFI partition for me is always at the end, if I happen to need more space I add it from the partition before it.

I don't know if it is possible to have the whole grub in the EFI partition, if there is no specific requirement for using grub I would give rEFInd a shot. Grub is easy to break and hard to repair, rEFInd in my experience has been the opposite.

Offline

#5 2024-02-20 12:11:34

Gonda
Member
Registered: 2023-09-07
Posts: 8

Re: Is it best practice to put grub on /efi?

V1del wrote:

The mount point in your system does in and of itself not matter at all. There's a logical distinction between mounting the ESP to /boot but that's not because the mount point is special but because kernel files get written to /boot by default.

So I'm not sure what you are actually asking. I install GRUB on "/efi" because I want it to access my kernel files directly on the root partition. If you want to share with debians GRUB anyway, you could just configure debian to load Arch's kernels and not explicitly install GRUB on Arch at all (though Arch's kernel recently dropped a compatibility option that might break older GRUBs so pending on what you have on your debian it might make sense to explicitly install Arch's GRUB as well).  But again the  mount point you operate GRUB with does not matter, as long as you aren't masking /boot

Sorry, I used non-clear language. I meant mounting the EFI partition to /boot or %efi%/grub to /boot/grub such that the bootloader files are not kept at distro level but on the system wide EFI partition. I'm fine with the kernels staying on the corresponding distro partitions since I'll likely not need them anymore when deleting a distro. Basically, I don't want to break the boot of the other systems if I need to delete Arch. Keeping the grub files on the EFI partition will make me able to still boot to Debian and update grub.

Last edited by Gonda (2024-02-20 12:25:40)

Offline

#6 2024-02-20 12:47:57

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,231

Re: Is it best practice to put grub on /efi?

Why would you not want the GRUB files of the system you might not be using to reside with said system? You're on an EFI system, if you want to you can have two completely distinct bootloaders and all you have to do for that is pass a different --bootloader-id to the grub-install command. If you want just one GRUB, then have just that one GRUB and configure it to load kernel images from the other system, the worst that can happen is that you have distinct but defunct "Arch Linux" or "Debian" entries depening on which bootloader you settle on.

But that's just my take, if you're going with your original approach don't forget to set both --efi-directory and --boot-directory paths to the grub-install command correctly.

Offline

Board footer

Powered by FluxBB