[syslinux] newbie question: pxelinux.cfg/default question

Andreas Kotes count-linux at flatline.de
Thu Mar 13 17:25:45 PDT 2008


Hello a.,

* a s p a s i a <aspasia.sf at gmail.com> [20080314 00:24]:
> I understand that during PXE boot, it goes into the pxelinux.cfg and it states:
> 
> 1. "it will search for the config file using its own IP address in
> upper case hexadecimal, e.g. 192.0.2.91 -> C000025B  (you can use the
> included progam "gethostip" to compute the hexadecimal IP address for
> any host.) If that file is not found, it will remove one hex digit and
> try again."
> 
> a. I'm quite confused - does that mean that the files C0000025B
> through "C" SHOULD exist or not?

they MAY exist. It will try C0000025B, then, C0000025, then C000002, and
so on, until one of them is found. If C is not found, it uses 'default'.

> b. Are these EMPTY files?

no. these are full configuration files :)

> c.  and Utlimiately it reads /pxelinux.cfg/default - which I have seen
> it to work.

yes.

> BUT, what if I want to have like (5) FIVE - configuration files, each
> of which I want to define a unique NFSroot per host?? ... example:
> 
> pxelinux.cfg/default1
> DEFAULT vmlinuz-2.6.22-14
> APPEND initrd=initrd.img-2.6.22-14
> nfsroot=192.168.16.5:/export/images/00A0D1E35838 ip=dhcp

this file should be called e.g. pxelinux.cfg/C0A81010 for host
192.168.16.16 to do what you want

> pxelinux.cfg/default2
> DEFAULT vmlinuz-2.6.22-14
> APPEND initrd=initrd.img-2.6.22-14
> nfsroot=192.168.16.5:/export/images/00A0D1E357CA ip=dhcp

this file should be called e.g. pxelinux.cfg/C0A81011 for host
192.168.16.17 to do what you want

> Is this possible - I tried to google and a few folks point to using
> the MAC address of the booting client - i tried to place a file:
> /pxelinux.cfg/00A0D1E35838
> which contains the appropriate above configuration, and yet still the
> boot process reads the pxelinux.cfg/default file.

it has to be the _IP address_ in hex, not the MAC address :)

good luck :)

   Andreas

-- 
flatline IT services - Andreas Kotes - Tailored solutions for your IT needs




More information about the Syslinux mailing list