DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

pxe(HW)


pxe -- PXE boot support

Description

This manual page explains how to configure and enable PXE network boot.

Preboot Execution Environment (PXE) refers to various methods of booting a system without the need for a hard drive or boot diskette. Many network cards support the PXE 2.1 standard and are capable of being used to boot the system from an image on the network.

PXE network boot uses the Dynamic Host Configuration Protocol (DHCP), the Address Allocation Server (AAS), the Internet Bootstrap Protocol (BOOTP), and the Trivial File Transfer Protocol (TFTP) to make the boot image available to the client.

In general, to configure and enable PXE network boot:

  1. Create a PXE configuration file on the system serving the bootable image.

  2. Configure DHCP, AAS, BOOTP, and TFTP. DHCP and AAS can be configured on the system serving the bootable image, or on any machine on the same subnet. BOOTP and TFTP need to be configured on the system serving the bootable image.

  3. Force inetd to reread its configuration file.

  4. Enable PXE boot on the client system and reboot to start the network boot process.

These steps are detailed in the subsections below.

PXE configuration file

When a client sends a boot request to the DHCP server on the subnet, the DHCP server directs it to the appropriate server, and may provide the name of a configuration file to be used by the server to start the PXE boot process.

This file can have any name, but must match the name specified for the boot_file in the DHCP server's configuration file (see below). In the examples on this manual page, we use the name pxebootldr for the PXE configuration file.

The format for pxebootldr is:

   name=value
where name can be any of the following (with default values shown):
   BOOTFILE="bootramd"
   BOOTPATH=""
   SERVER_IP=""
   GATEWAY_IP=""
   TFTP_PORT="69"
   TFTP_PKTSIZE="512"

BOOTFILE is the name of the bootable image, and BOOTPATH is an optional path where the image resides. Note that the BOOTFILE and BOOTPATH parameters are taken relative to the path specified if tftpd was started with the -s option (see below). For example, if tfptd was started with -s /tftpboot, then a BOOTPATH of /tftpboot would be interpreted as /tftpboot/tftpboot by the TFTP server.

SERVER_IP can be used to specify the IP address of an alternate TFTP server from which the bootable image is to be obtained. The GATEWAY_IP is needed if the SERVER_IP is on another subnet.

TFTP_PORT is used to specify a TFTP server port other than the default (69), and TFTP_PKTSIZE specifies another packet size to be used for packets exchanged with the TFTP server.

In many cases, the only parameter needed will be BOOTFILE to specify the name of the bootable image to be passed to the client. If no BOOTFILE is specified, or if no PXE configuration file is found, then the PXE code looks for a file named bootramd.

Configuring DHCP for PXE network boot

The DHCP server configuration file (/etc/inet/dhcpd.conf) must be updated to contain at least the following directives that tell the client which system to contact for the boot image (boot_server) and the name of the PXE configuration file (boot_file). This can be done through scoadmin or by editing the file to contain directives like those shown below:
   subnet X.X.X.X {
       boot_file /pxebootldr
       boot_server X.X.X.X
       domain "server.domain"
       routers X.X.X.X
       pool PXEbootPool
   }

The boot_file directive tells the client the name of the PXE configuration file on the TFTP server, specified as boot_server. Note that boot_file will be interpreted on the system serving the bootable image relative to any directory specified with the -s option when tftpd is started. See the description of inetd.conf, below.

The pool directive tells the DHCP server which pool of addresses (managed by the Address Allocation Server, or AAS) is available for use by clients. See the following section.

Configuring AAS for PXE network boot

The AAS configuration file (/etc/inet/aasd.conf) must be updated to contain at least the following directives that tell the DHCP server which addresses are available to be assigned to clients. This can be done through scoadmin or by editing the file to contain a directive like the one shown below:
   pool PXEbootPool:INET {
            X.X.X.X-X.X.X.X
   }

Any name can be used for the pool name, as long as it matches the pool directive specified in dhcpd.conf, above.

Note that if DHCP is being run on another system on the network, the AAS server should be run on that system as well.

Enabling PXE network boot

Once the instructions in the previous sections are completed, follow these instructions to start TFTP, BOOTP, and DHCP:

  1. TFTP is usually enabled on the server by editing the file /etc/inet/inetd.conf and removing the pound character (#) from the beginning of these lines:
       #tftp   dgram   udp     wait    root    /etc/tftpd      tftpd -s /tftpboot
       #tftp   dgram   udp     wait    root    /etc/tcpd       tftpd -s /tftpboot
    

    This enables the TFTP server in secure mode, where the booting client can only access files under the specified directory; in this case, /tftpboot. You can also enable tfptd without the -s option, but this opens up every world-readable file on your system to being read over the network and should be done only where this risk does not pose a threat (such as on a subnet located behind a secure firewall).

    The directory /tftpboot (or whatever directory is used) must be created manually, and populated with at least the bootable image to be downloaded. The default image file name is bootramd. Whatever directory and file names are used, they must match the names specified to the DHCP server (see below).

  2. The BOOTPD and DHCP servers are started by adding the following lines to /etc/inet/inetd.conf:
       bootps dgram/i udp     wait    root    /etc/dhcpd      dhcpd -b bootps-alt
       bootps-alt dgram udp   wait    root    /etc/bootpd     bootpd -S -c /tftpboot
    

    The directory spcified for bootpd with the -c option must match the directory specified above for tftpd with the -s option (in this case, /tftpboot).

    Note that, if desired, the DHCP server could be located on another system on the subnet. See the comments in inetd.conf to configure BOOTP without DHCP.

  3. Force the inetd daemon to reread its configuration file by entering these two commands:
       ps -eaf | grep inetd
       kill -HUP PID
    
    Where PID is the process ID of the inetd daemon.

Configuring the client for PXE network boot

In order to install a clent system over the network, the Network Interface Card (NIC) on the system to be installed must support the PXE 2.1 standard and be on the same subnet as the servers configured in the previous sections.

If your network card does not support PXE 2.1, you must update the card's BIOS to include PXE 2.1 support (or use another card). Check the documentation for your networking card. Most network card vendors offer BIOS upgrades on their web sites. (Updates for older Intel Pro/100 cards, for example, are available from http://www.intel.com.) Use the Search box on the network card manufacturer's web site to find the manufacturer's available updates for your card. Instructions for applying the updates are provided by the manufacturer.

Once you are sure that the client's network card supports PXE 2.1 and that the system is on the same subnet as the DHCP server, reboot the client and enter the system BIOS. Enable booting from the network in the system's BIOS, save your changes, and reboot.

As the client comes up, it should display information about the network card's PXE agent, including the key to press to start the PXE boot process. When you press this key, a boot request is sent to the DHCP server on the subnet, which should respond with the location of the boot_server, the name of the boot_file, and the other DHCP parameters (as set above). The client then contacts the boot server and downloads the network bootable image.

See also

aasd(ADMN), bootpd(ADMN), dhcpd(ADMN), tftpd(ADMN)

Standards conformance

This implementation of PXE conforms to the PXE 2.1 Specification.
© 2007 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 05 June 2007