Booting quickly?
I currently use GRUB as my bootloader, because it's IMO it seems the most reliable and well-tested option. However, on one of my machines which boot really fast, GRUB with its menu and all that is too slow for me.
Should I switch to another bootloader? If so, which one is the most reliable (I don't dual-boot on that machine, so no dual-boot support needed)? Or can I modify GRUB options to make it really fast?
About this post
- Posted
- Archived
- Score
- 17 · 100% up
- Kind
- Text
- ID
- bco38h
20 comments
The fastest and most reliable way to boot is to not use a bootloader and boot directly from UEFI using EFIStub and efibootmgr. It is not actually as hard as it sounds.
From my experiences systemd boot is much more reliable and easier to use than grub. If want to boot fast, you can set timeout to zero and it will boot in a few milliseconds.
If anyone is looking for boot managers then I recommend refind.
I second this
I've tried this before, but as I remember it, a few of my kernel parameters stopped working for some reason after I had done it.
I don't remember what they were exactly, but the dealbreaker for me was that I could no longer specify the
rootpartition with the UUID, i.e.root=UUID=aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee; I could only use /dev/sd* names to boot. This was important to me because the kernel liked switching my main drive to /dev/sdb or /dev/sdc whenever I had USBs or other drives plugged in while booting, and I didn't want to be second-guessing which drive letter it was everytime I booted.I think I might've just overlooked something, but that's when I decided to just switch to systemd-boot, and since then, it has never given me any problems.
That's most likely a problem with your mainboard's firmware being out of spec and not accepting long parameters. Which is pretty common, since Windows doesn't need parameters, and that's all they test.
I give my partitions labels for this exact reason
Rather than UUID it becomes root=LABEL=SYSTEM or whatever you named it
The kernel recognizes it just fine
Is there a way to change a bootloader on an already working system? I've looked into this, but didn't see any info. Would I want to switch from GRUB to systemd or should I just wait until I get a new computer and install it there?
Just install another one? There's nothing stopping you from doing so.
This. And enable ultra fast boot in your uefi settings.
Of course it takes a long time for dm-crypt to unlock my root partition and a long time for btrfs to recognise my array.
You can adjust the wait time in the
/etc/default/grubfile, with theGRUB_TIMEOUTentry. If you set it to zero and regenerate GRUB config, it'll skip the menu.Grub2 is full of options and tweaks, but I always preferred to use syslinux or bootd, simpler, and imo faster (subjectively). If you only need to boot your system, they do the job.
Deleted before we saved it.
https://aur.archlinux.org/packages/grub-holdshift/
The fastest option will always be an efi stub, but if you want to try out what works best for you, just install the ones you want to try, and add them as a boot option in your bios/uefi. They'll sit in their respective directory, which you will be able to remove safely.
Personally, I'm a fan of rEFInd. Easy to configure, looks nice (with themes), boot entries (rEFInd calls them stanzas) are nicely customizeable as well.
Boot from UEFI shell directly. Plus got to trim your boot options. Like services you you don't need should be trimmed off the boot level.
Linux kernel is efi image for long time and it should boot fast provided you trimmed down your boot process requirement.
Can you give us the output of this command:
Stub loading is the fastest. I have my boot time to a few seconds, most of which is the “Lenovo” logo
I guess it's ThinkPad? Any way to speed up the firmware boot times? Mine is always around 5-6 seconds.
There are some things you can do, yes.
Turn off every feature in the bios you don’t use. Turn off all devices in the boot menus except the device with your efi on it. Make sure you’re on the latest firmware. Turn on fast boot/quick boot. If there’s options to skip some post flags, set that. Basically, make your motherboard process as little as possible.
Im also a systemd-boot fan. Not only because it boots fast, but I don't have to give a fuck about what Filesystems my bootloader supports in what way.
I'm sure you can configure grub to make it faster, but I prefer systemd-boot as it's much simpler and easier to configure. It only works with uefi though.