PXEBOOT(8)

πŸ“¦ version 15.1, in freebsd 14.5, freebsd 15.1

🌸 PXEBOOT(8) β€” the glow-up era of bootloaders 🌸

okay so bestie, let me tell you about pxeboot β€” it's the Preboot Execution Environment (PXE) bootloader, and honestly? it's giving main character energy in the diskless-machine world. πŸ’…


✨ NAME ✨

pxeboot β€” Preboot Execution Environment (PXE) bootloader. yeah. that's the whole name. iconic, brief, slay. πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so first things first: the pxeboot bootloader is literally a modified version of the system third-stage bootstrap loader(8), but it's been configured to run under Intel's Preboot Execution Environment (PXE) system. PXE is basically a form of smart boot ROM β€” no cap β€” and it's built into Intel EtherExpress Pro/100 and 3Com 3c905c Ethernet cards, plus Ethernet-equipped Intel motherboards. PXE supports DHCP configuration AND provides low-level NIC access services. it's doing the most, and we love that for it. πŸ”₯

the DHCP client will set a DHCP user class named FreeBSD to allow flexible configuration of the DHCP server. yes bestie, it's tagged. iykyk. πŸ’œ

the pxeboot bootloader retrieves the kernel, modules, and other files either via NFS over UDP or by TFTP, selectable through compile-time options. and when you combine it with a memory file system image or an NFS-mounted root file system, pxeboot allows for easy, EEPROM-burner free construction of diskless machines. literally no EEPROM burner required. we are thriving. ✨

the pxeboot binary is loaded just like any other boot file β€” you just specify it in the DHCP server's configuration file. below is a sample configuration for the ISC DHCP v3 server, and yes i'm pasting it exactly because details matter and i would never do you dirty like that:

option domain-name "example.com";
option routers 10.0.0.1;
option subnet-mask 255.255.255.0;
option broadcast-address 10.0.0.255;
option domain-name-servers 10.0.0.1;
server-name "DHCPserver";
server-identifier 10.0.0.1;
next-server 10.0.0.1;

default-lease-time 120;
max-lease-time 120;

subnet 10.0.0.0 netmask 255.255.255.0 {
       filename "pxeboot";
       range 10.0.0.10 10.0.0.254;
       if exists user-class and option user-class = "FreeBSD" {
            option root-path "tftp://10.0.0.1/FreeBSD";
       }
}

next-server is the IP address of the next server in the bootstrap process β€” i.e. your TFTP server or NFS server. pxeboot recognizes option root-path directives as the server and path to NFS mount for file requests, respectively, or the server to make TFTP requests to. and like, note this: pxeboot expects to fetch /boot/loader.rc from the specified server before loading any other files. so don't skip that step, bestie. πŸ™ˆ


πŸŽ€ valid option root-path syntax πŸŽ€

here's the whole menu, and you already know i'm listing every single one:

  • /path β€” path to the root filesystem on the NFS server
  • ip://path β€” path to the root filesystem on the NFS server ip
  • nfs://path β€” path to the root filesystem on the NFS server
  • nfs://ip/path β€” path to the root filesystem on the NFS server ip
  • tftp://path β€” path to the root filesystem on the TFTP server
  • tftp://ip/path β€” path to the root filesystem on the TFTP server ip

🌈 a lil note on packet sizes 🌈

pxeboot defaults to a conservative 1024 byte NFS data packet size β€” very demure, very mindful. this may be changed by setting the nfs.read_size variable in /boot/loader.conf. valid values range from 1024 to 16384 bytes. so like, don't go rogue and put 99. the range is the range. ⭐

in all other respects, pxeboot acts just like loader(8). periodt. πŸ’…

for further information on Intel's PXE specifications and Wired for Management (WfM) systems, see http://www.pix.net/software/pxeboot/archive/pxespec.pdf. go read it, it's giving homework but make it networking. πŸ“š


🫢 SEE ALSO 🫢


πŸ’– HISTORY πŸ’–

the pxeboot bootloader first appeared in FreeBSD 4.1. a true pioneer. we stan an OG. πŸ‘‘


🧚 AUTHORS 🧚

the pxeboot bootloader was written by John Baldwin <jhb@FreeBSD.org> and Paul Saab <ps@FreeBSD.org>. this manual page was written by Doug White <dwhite@FreeBSD.org>. absolute legends, every single one. no cap. 🌟


and that's the whole thing bestie β€” from Debian, dated February 15, 2021. you're welcome, go boot something diskless and think of me. πŸ’œβœ¨πŸ¦‹

πŸ“¦ where this page comes from