Table of Contents

PXE

HOWTO boot a PXE client with DHCPD and an Altiris Bootserver all in different VLANs/Subnets…

without relaying all DHCPDISCOVER packets to the Bootserver.

The goal is to redirect a client towards a PXE-bootserver with parameters from the DHCP-server only.

Easy part: All clients to one bootserver

if substring (option vendor-class-identifier, 0, 9) = "PXEClient" {
   option vendor-class-identifier "PXEClient";
   option dhcp-server-identifier bootserver.chen.de;
   server-name "bootserver.chen.de";
}

Detour 1: Present the menu via the DHCP-Server

    option space PXE;
    option PXE.mtftp-ip               code 1 = ip-address;
    option PXE.mtftp-cport            code 2 = unsigned integer 16;
    option PXE.mtftp-sport            code 3 = unsigned integer 16;
    option PXE.mtftp-tmout            code 4 = unsigned integer 8;
    option PXE.mtftp-delay            code 5 = unsigned integer 8;
    option PXE.discovery-control      code 6 = unsigned integer 8;
    option PXE.discovery-mcast-addr   code 7 = ip-address;
    option PXE.boot-server            code 8 = { unsigned integer 16,
                                                 unsigned integer 8,
                                                 ip-address };
    option PXE.boot-menu              code 9 = { unsigned integer 16,
                                                 unsigned integer 8,
                                                 text};
    option PXE.menu-prompt            code 10 = { unsigned integer 8, text };
    class "pxeclients" {
       match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
       option vendor-class-identifier "PXEClient";
       vendor-option-space PXE;
       #option PXE.mtftp-ip         0.0.0.0;  # multicast TFTP off
       option PXE.discovery-control 7;
       option PXE.discovery-mcast-addr 0.0.0.0;
       option PXE.boot-server 10 1 a.b.c.d;
       option PXE.boot-menu 10 8 "Welcome!";
       option PXE.menu-prompt 0 "Welcome!";
    }

This has the drawback that the Bootmenu is sent by the DHCPD. So the fancy dynamic Boot selection from Altiris is not available.

Advanced solution: Some clients to a set of bootservers

in a sufficiently large environment, there is no such thing as a standardisation on a “single” solution anymore. In one pathologic case i had about 6 different installation methods for different types of clients simultaneously (3 different Altiris Deployment Servers, Tivoli Provisioning Manager, Lanworks, Prodacta Pronet, pxelinux, SUN Jumpstart, …)

The challenge was to direct each client to their “right” bootserver. To achieve this, i wrote a PXE-relayagent for the DHCP-Server. The relay agent receives the PXE-request from the client, checks it against a SQL table with client/server pairs and sends it towards the corresponding bootserver. The reply from the bootserver is then relayed back to the client. If the client is not known, the relay instructs the client to “boot from local disk”.

  insert code here