You are not logged in.

#1 2015-11-07 06:32:30

Dord
Member
From: The mountains
Registered: 2015-11-03
Posts: 17

[SOLVED] Removing GRUB

Hey guys,

I have switched from grub to rEFInd, simply because it looks better in my opinion.

Everything works great, but I have just a quick question, while Grub is both a boot loader and boot manager, rEFInd is only a boot manager, but from what I read online, recent kernels have a built-in boot loader. So basically my question is, is Grub still of any use to my system, or can I now safely just remove it?

I just want to make sure.  ops

Thanks!

Last edited by Dord (2015-11-08 18:49:12)

Offline

#2 2015-11-07 07:32:34

ohnonot
...again
Registered: 2015-09-29
Posts: 5,554

Re: [SOLVED] Removing GRUB

there seems to be some confusion here, but i'm not good enough with efi-related matters to give constructive advice...

Dord wrote:

I read online, recent kernels have a built-in boot loader.

can you show us?


Give to COVAX! Here or here. (explanation)

Offline

#3 2015-11-07 10:36:06

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: [SOLVED] Removing GRUB

Dord wrote:

recent kernels have a built-in boot loader

This is the CONFIG_EFI_STUB option [1] which allows the kernel to boot itself in a UEFI system.

For this to work, the kernel image must be located on the EFI system partition.

This is what is recommended in Arch -- /boot is mounted to the ESP in most cases.

Unfortunately, in Debian dpkg(1) will refuse to install the kernel image to a non-POSIX compliant filesystem (the ESP must be FAT-formatted for it to be readable by UEFI firmware) so this is not possible therefore the ESP is mounted to /boot/efi and a bootloader is used instead (ie, GRUB).

I boot my Debian systems using systemd-boot (previously know as gummiboot) and I use a kernel postinstall script to copy the kernel image to the ESP after upgrades:

# /etc/kernel/postinstall.d/zz-update-esp
mount /dev/sda1 /mnt # the ESP is on /dev/sda1
cp /vmlinuz /initrd.img /mnt/debian # Debian symlinks the current kernel image & initrd to the root directory (the name is always the same, unlike the kernel image in /boot)
umount -R /mnt

I have no idea how rEFInd works though, sorry.

[1] https://www.kernel.org/doc/Documentation/efi-stub.txt


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#4 2015-11-07 17:43:07

tynman
Member
Registered: 2015-10-13
Posts: 88

Re: [SOLVED] Removing GRUB

I also switched from grub to booting with refind. I now never see a grub boot screen. (And I don't miss it)

The reason I switched was to explore alternatives to grub. Over the years, I had never found grub to be very friendly or easy to configure, and the documentation confused me (not hard to do). I found refind to be quite well documented, and while it took a while for me to get working, I didn't find it "difficult". And it seems to work just fine.

I'm not sure what the difference is between boot manager and boot loader, but just going with my gut feel what those terms mean, I would say both grub and refind address both functions. Maybe I'm missing something there.

But it never occurred to me to "remove" grub -- I wouldn't even know how. If someone could offer some ideas on how one would remove grub, I would be willing to give it a try and report back.

...Ben

Offline

#5 2015-11-07 18:01:31

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 8,759
Website

Re: [SOLVED] Removing GRUB

tynman wrote:

I'm not sure what the difference is between boot manager and boot loader

Quoting from Rod Smith's rEFInd site:

rEFInd is a boot manager[...] rEFInd is not a boot loader, which is a program that loads an OS kernel and hands off control to it. (Since version 3.3.0, the Linux kernel has included a built-in boot loader, though, so this distinction is rather artificial these days, at least for Linux.) Many popular boot managers, such as GRUB, are also boot loaders, which can blur the distinction in many users' minds. All EFI-capable OSes include boot loaders, so this limitation isn't a problem. If you're using Linux, you should be aware that several EFI boot loaders are available, so choosing between them can be a challenge. In fact, the Linux kernel can function as an EFI boot loader for itself, which gives rEFInd characteristics similar to a boot loader for Linux.

http://www.rodsbooks.com/refind/

Briefly: bootmanagers just hands the booting process over to an .efi loader (which may be a GRUB binary or an EFI_STUB enabled kernel image) whereas a bootloader is capable of conducting the booting process itself.


“Et ignotas animum dimittit in artes.” — Ovid, Metamorphoses, VIII., 18.

Forum Rules   •   How to report a problem   •   Software that rocks

Offline

#6 2015-11-07 20:25:38

Dord
Member
From: The mountains
Registered: 2015-11-03
Posts: 17

Re: [SOLVED] Removing GRUB

Thanks for the info guys.
So GRUB is still handling the boot loading, I'd have to configure and make sure EFI_STUB handles it before removing it. It doesn't really bother me to have grub installed, I was just curious.

I don't really have time to look into it at the moment, so I'll add it to my todo list and dive into that later!  smile

Offline

Board footer

Powered by FluxBB