Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] Kernel parameters over HTTP in EFI
2019-02-22, 09:00 (This post was last modified: 2019-02-25 22:41 by NiKiZe.)
Post: #1
[SOLVED] Kernel parameters over HTTP in EFI
Hello,

I am booting ipxe.efi over network and provide it this script:

Code:
#!ipxe
dhcp
kernel http://xxx/boot/fdi-image/vmlinuz0 rootflags=loop root=live:/fdi.iso rootfstype=auto
initrd http://xxx/boot/fdi-image/initrd0.img

It works fine in BIOS as root kernel command line option is passed in (this is a LiveCD which needs root option to be present). However, when I try this in EFI mode, I am getting kernel panic because it seems like no kernel command line parameters are passed in.

Is there a way to pass in kernel command line parameters in EFI?

(By the way I noticed that ipxe.efi works also in BIOS mode, does it mean it is compatible with both BIOS and EFI? Interesting stuff. -- EDIT it was a QEMU VM and it booted directly via iPXE that's why it worked).
Find all posts by this user
Quote this message in a reply
2019-02-22, 11:53
Post: #2
RE: Kernel parameters over HTTP in EFI
I wonder if this is related:

http://lists.ipxe.org/pipermail/ipxe-dev...05820.html
Find all posts by this user
Quote this message in a reply
2019-02-22, 12:16 (This post was last modified: 2019-02-24 08:58 by NiKiZe.)
Post: #3
RE: Kernel parameters over HTTP in EFI
You can see some information in the FAQ about initrd in efi land.
One thing to check before boot is imgstat to see which arguments are sent.

And no it is not possible to run efi code in pcbios mode or the other way around - also covered in the FAQ in the forum.

Use GitHub Discussions
VRAM bin
Visit this user's website Find all posts by this user
Quote this message in a reply
2019-02-22, 12:18
Post: #4
RE: Kernel parameters over HTTP in EFI
(2019-02-22 11:53)lzap Wrote:  I wonder if this is related:

http://lists.ipxe.org/pipermail/ipxe-dev...05820.html

No that patch is about sending commands on the cmdline to ipxe in efi mode.

Use GitHub Discussions
VRAM bin
Visit this user's website Find all posts by this user
Quote this message in a reply
2019-02-24, 08:53 (This post was last modified: 2019-02-24 08:55 by MultimediaMan.)
Post: #5
RE: Kernel parameters over HTTP in EFI
RE: Kernel Panic (VFS error); This is a Common "Problem" in EFI... EFI explicitly needs to know the name of the initrd as part of the kernel command line.

Try:
Code:
#!ipxe
dhcp
initrd http://xxx/boot/fdi-image/initrd0.img
kernel http://xxx/boot/fdi-image/vmlinuz0 initrd=initrd0.img rootflags=loop root=live:/fdi.iso rootfstype=auto

You might have to play around with the "root=" portion of the command line... usually, if it works from the ISO in EFI mode in this manner, it *should* work in iPXE. It just matters where the kernel parameters are being applied.

Best,

M^3

"Thus far, you have been adrift within the sheltered harbor of my patience..."
Find all posts by this user
Quote this message in a reply
2019-02-25, 11:28
Post: #6
RE: Kernel parameters over HTTP in EFI
(2019-02-22 12:16)NiKiZe Wrote:  You can see some information in the FAQ about initrd in efi land.

Great, thanks it works now!

Code:
#!ipxe
dhcp
kernel http://xxx/boot/fdi-image/vmlinuz0 initrd=initrd0.img rootflags=loop root=live:/fdi.iso rootfstype=auto
initrd http://xxx/boot/fdi-image/initrd0.img
Find all posts by this user
Quote this message in a reply
2019-02-25, 22:41
Post: #7
RE: Kernel parameters over HTTP in EFI
Awesome! Always good when there is easy solutions Wink

Use GitHub Discussions
VRAM bin
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)