Wednesday, February 17, 2010

PXE chaining to modernize legacy PXE NICs

Ok - so we have faulty/legacy PXE implementation in some onboard NICs, that don't support "next-server"...  Here is how to fix...   VERY cool!  It basically replaces the faulty PXE with a modern gPXE.

Following these instructions.. build undionly.kpxe and place in local /tftpboot/

http://etherboot.org/wiki/pxechaining

Then do something like the following in dhcpd.conf:

group {
        allow booting;
        option root-path "192.168.202.4:/opt/ltsp/i386";

        host ws042 {
                hardware ethernet 00:06:29:DF:2C:52;
                fixed-address ws042.dainty.ca;
                option host-name "ws042";

                if substring (option vendor-class-identifier, 0, 9) = "PXEClient" {
                        if exists user-class and option user-class = "gPXE" {
                                next-server 192.168.202.4;
                                filename "/ltsp/i386/pxelinux.0"; #secondary PXEclient
                        } else {
                        filename  "/tftpboot/undionly.kpxe"; #first boot.. loads gPXE
                        }
                } else {
                        next-server 192.168.202.4;
                        filename  "/ltsp/i386/nbi.img";  #normal boot image
                 }

        }
}