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

Knut Petter kpolberg at olberg.name
Thu Mar 13 18:03:19 PDT 2008


Just a little note. You would usually specify the  IP in the DHCP server.

ex.

host elwood {
        hardware ethernet 08:00:69:13:08:8b;
        fixed-address 192.168.16.16;
}
To make it load the C0A81010 config file.

Knut Petter

Andreas Kotes wrote:
> 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
>
>   




More information about the Syslinux mailing list