[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
GRUB2: Oldest supported Linux Kernels
From: |
Robin Gay |
Subject: |
GRUB2: Oldest supported Linux Kernels |
Date: |
Tue, 5 Dec 2023 16:55:57 -0500 |
Hello GRUB support,
*Warning:* this question is purely informative for my own technical
challenge purposes and I am sending it because I'm not sure I understand
the 'Supported kernels' page from GRUB2 documentation. I'll perfectly
understand if it is considered irrelevant.
*I am sending this e-mail to ask:*
what would be the oldest Linux Kernel (including the ones not maintained by
Linux anymore) that GRUB2 is able to boot on a x86_64 UEFI platform?
I've tried booting 3.3, but GRUB2 told me that "kernel is too old".
I've seen the indications about "legacy" and "modern" protocols in the
manual (
https://www.gnu.org/software/grub/manual/grub/grub.html#Supported-kernels),
but the Linux x86 Boot Protocol page (
https://www.kernel.org/doc/html/latest/arch/x86/boot.html) reports 2.x
protocol being in place since Kernel 1.3.73.
*A bit of background:*
I am relatively new to Linux (well, it's been 2 years and 2 different
distros) and I am very interested in understanding how the Kernel works. As
I own a version of *Understanding the Linux Kernel* that goes through
Kernel 2.6, I would like to see it running to be able to (re)read the book
along with it running (and also, be able to tell myself and the people I
will be willing to -- unsuccessfully -- impress that I've installed and
booted Linux 2.6 on my modern laptop). I've managed to build Linux From
Scratch 6.8 (GLibc 2.13, GCC 4.5.2) using a Docker container, make the
chroot work, cross-compile and all, and it boots ok in a Qemu VM (with KVM
and Qemu's direct kernel boot support). But since I am very stubborn I am
willing to boot it on my 2020-ish x86_64 UEFI Lenovo laptop (yeah, I guess
half the hardware was not even being engineered when Linux 2.6 came out,
but you know, technical challenge, am I right?! And also, x86 retro-compat,
I guess).
So far I've tried GRUB2, GRUB Legacy 1.98 and 2.00 (I'm pretty sure it's
Legacy 2.00 and not GRUB2 from the age of the release), from which I
guessed that:
1) GRUB2 told me "kernel ver magic is invalid", and since I am no Kernel
developer (yet), neither am I able to read binary files (yet!!!!), I
decided that GRUB2 must be too recent for this Kernel;
2) GRUB Legacy EFI bugs on "Can't find frame buffer address", and by
looking at GRUB Legacy's code and my PC's FB address my guess is that GRUB
Legacy is looking for a 32-bit address while my machine has it 64-bit. But
I don't want to try and patch GRUB Legacy as I lack C programming skills
and platform knowledge to do so.
I've also tried to boot with ELILO, not really hard yet but seeing the age
of the software I guess I'll run into the same problems as with GRUB
Legacy. SYSLINUX seems to be a similar alternative, but it also roughly is
the same age.
Finally I've tried U-Boot but couldn't even have it display correctly on my
machine. Not even talking about booting Linux. I guess this would be the
go-to, though, as it's widely used in weird architecure-, insanely old
software-equipped SoCs and embedded systems, but before learning U-Boot I
wonder if I can manage to use GRUB2 (yes, this is actually about laziness).
Seeing all these failures I decided to try a more recent Linux, 3.3,
because it supports EFI Stub. (Also I discovered that NVME support has been
implemented around early 3.x, so I guess booting Linux 2.6 on my fantastic
NVME SSDs is literally impossible (unless I become a Kernel developer and
patch 2.6 on my own, but I would like to keep my social life for a bit
longer before that)). I didn't dig much into EFI Stub, apart from trying to
chainload it from GRUB 2 using chainloader, with absolutely no indication
to do so apart from the fact that this is the way I launch the other
bootloaders I've tried, so I guessed this could maybe work. This failed
unsurprisingly with "cannot load image". (Maybe trying to setting it as an
EFI entry would do? But I'd like to keep my main GRUB2 as a boot manager
anyway.)
So I went through the several attempts again with my new kernel 3.3, and
this time GRUB2 told me explicitely: "Kernel is too old" when using the
linux command. Hence my question, as I would like to know if I will be able
to find a kernel that:
1) supports the LFS 6.8 system I built;
2) is not too far from 2.6; and
3) GRUB2 is able to boot.
*Thanks in advance for your time if you read all this!*
And sorry if my question is dumb / irrelevant.
Best regards,
R. GAY
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- GRUB2: Oldest supported Linux Kernels,
Robin Gay <=