While reading the PXELINUX documentation I came across an option which
may be of use [1]. Adding 'ipappend 2' to the host's pxelinux config
file makes PXELINUX append the mac address of that interface to the
kernel options.

Example:

BOOTIF=01-AA-BB-CC-DD-EE-FF

This allows the initrd to access to the mac address of the interface
which PXE booted and is probably the interface we want to use for DHCP.

Obviously, this allows someone to set this kernel option without the
need for PXE booting (which is an added bonus).

I have written a script (attached) which I'm executing from the debian-
installer-startup.d directory of the initrd. The script reads the value
of the 'BOOTIF' kernel option and looks to see if there is an interface
name with this mac address. It then uses 'debconf-set' to change the
'netcfg/choose_interface' option to this interface name.

The script may be a little rough around the edges, and specific to
PXELINUX, but seems to work when tested on a variety of hardware running
Hardy (8.04.2).

Example

/var/lib/tftpboot/pxelinux.cfg/default:

LABEL install
        kernel hardy-amd64
        ipappend 2
        append interface=auto [the rest of your options]

[1]:
http://syslinux.zytor.com/wiki/index.php/SYSLINUX#IPAPPEND_flag_val_.5BPXELINUX_only.5D


** Attachment added: "S31pxedust"
   http://launchpadlibrarian.net/22014511/S31pxedust

-- 
provide a method to use a specified MAC-address as the installation device
https://bugs.launchpad.net/bugs/56679
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to