iPXE discussion forum

Full Version: can ipxe boot a FreeBSD kernel?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi

The standard way to boot FreeBSD via pxe is to chainload /boot/pxeboot wich resembles a complete pxe bootloader, wich is fine if FreeBSD is the only OS one wants to boot.
Unfortunatly it isn't if one wants to boot multiple OS via PXE or even several versions of FreeBSD for the following reasons:

1. it unnecessarily takes time for initializing the nic and requesting an ip (again, after first the NICs boot ROM did this, and ipxe did this too because it is chainloaded from the NIC's boot ROM)
2. it sends its own dhcp client id so I can't use the id to trigger different dhcp-options based on it (because I can't set it in any configuration file)
3. it doesn't support scripting at all
4. it relys on "option root-path" set by the dhcp server wich can't be overridden by any means I know, preventing me from booting anything else wich needs "option root-path".

So I want to know if ipxe is able to direct-boot a FreeBSD Kernel (8.2-RELEASE-amd64 and 9.0-RELEASE-amd64) without chainloading FreeBSD's own pxeboot and, if so, how to do it. This is what I tried (and didn't work):

Code:
#!ipxe
dhcp
set root-path 192.168.23.1:/usr/data/tftpboot/clients/fbsd64
kernel tftp://192.168.23.1/clients/fbsd64/boot/kernel/kernel
boot
This locks the machine completely.
Any hints, ideas?

with kind regards,
errorsmith
(2012-03-02 19:28)errorsmith Wrote: [ -> ]So I want to know if ipxe is able to direct-boot a FreeBSD Kernel (8.2-RELEASE-amd64 and 9.0-RELEASE-amd64) without chainloading FreeBSD's own pxeboot and, if so, how to do it. This is what I tried (and didn't work):

Code:
#!ipxe
dhcp
set root-path 192.168.23.1:/usr/data/tftpboot/clients/fbsd64
kernel tftp://192.168.23.1/clients/fbsd64/boot/kernel/kernel
boot
This locks the machine completely.
Any hints, ideas?

From memory, and quite possibly inaccurate:

32-bit FreeBSD kernels are Multiboot-compliant, which allows them to be booted by iPXE. 64-bit kernels are not, and require a dedicated FreeBSD bootloader.

Does it work if you use another intermediate bootloader such as pxelinux.0 to load the FreeBSD kernel?

Michael
(2012-03-02 19:35)mcb30 Wrote: [ -> ]From memory, and quite possibly inaccurate:

32-bit FreeBSD kernels are Multiboot-compliant, which allows them to be booted by iPXE. 64-bit kernels are not, and require a dedicated FreeBSD bootloader.

Does it work if you use another intermediate bootloader such as pxelinux.0 to load the FreeBSD kernel?

Michael

D'oh!
In fact I am trying to boot a 64bit kernel.
And no, it doesn't work if I use another intermediate loader.
The only way to load the 64bit kernel seems to be FreeBSDs pxeboot. I didn't try a 32bit version and I can't try it right now because I don't have a 32bit installation ready.
So this seems to be a no-go right now? Any chance this will be possible in the future? I'm not a coder but willing to help if I can.

errorsmith
Reference URL's