[arch-releng] [PATCH] [configs/releng] Make kernel and initramfs patch relative for syslinux

Thomas Bächler thomas at archlinux.org
Thu Nov 24 09:44:04 EST 2011

Am 24.11.2011 15:32, schrieb Gerardo Exequiel Pozzi:
> I need to test this, I am going to work now. (working for HTTP, but not
> for TFTP)
> ---- /tmp/pxeboot/arch/boot/syslinux/pxelinux.cfg ----
> DEFAULT loadconfig
> LABEL loadconfig
>   CONFIG /arch/boot/syslinux/syslinux.cfg
>   APPEND /arch/boot/syslinux/
> -------
> dnsmasq --port=0 --enable-tftp --tftp-root=/tmp/pxeboot
> --dhcp-boot=/arch/boot/syslinux/gpxelinux.0,
> --dhcp-range=,,8640 --dhcp-option-force=210,/
> --dhcp-option-force=209,/arch/boot/syslinux/pxelinux.cfg

HTTP servers resolve ".." inside URLs, TFTP servers probably don't. This
could be a showstopper.

However, I think we can work around this whole problem (including the
loadconfig trick) if we teach pxelinux.0 to resolve ../ in path names by
removing path components (in the TFTP client). I'll see if I can wrap up
a patch for pxelinux and get it accepted upstream.

Explanation: TFTP is stupid: It doesn't even understand paths.
pxelinux.0 probably just concatenates the tftp prefix from DHCP with the
file name and sends it as a request. A patch would have to convert
/arch/boot/syslinux/../i686/vmlinuz to /arch/boot/i686/vmlinuz, which
would be an existing file on TFTP.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 900 bytes
Desc: OpenPGP digital signature
URL: <http://mailman.archlinux.org/pipermail/arch-releng/attachments/20111124/666c797c/attachment.asc>

More information about the arch-releng mailing list