[syslinux] Nested PXELINUX configurations

Giannis Roussos morpheus at csl.mech.ntua.gr
Mon Mar 28 06:11:33 PDT 2011


OK, this is clear but still does not answewr my question, since from 
what I understand the prefix can't be changed without modifying the dhcp 
configuration and rebooting.

In other works, you say that paths are relative meaning that they are 
taken with respect to the location of the first pxelinux.0 loaded 
(usually the tftp root, so empty prefix), while I need relative paths in 
the sense that a 1.cfg file can include another 2.cfg by only its 
relative path with respect to the 1.cfg, regardless of their place in 
the tftp tree.

I will try to explain more clearly what I want to do:
Imagine a working pxelinux configuration that has a file structure like 
this ([braces] show directories, tftproot_1 is the root of the tftp server):

[tftproot_1]
   |-pxelinux.0
   |-[pxelinux.cfg]
	|-default
   |-[boot_screens]
	|-menu.cfg // additional config called by "default"

The "default" config calls the menu.cfg with a "include 
boot_screens/menu.cfg" line.

Now imagine that I want the above configuration to become an option in 
another pxelinux configuration, say [tftproot_2], i.e. add is a menu 
option in an existing pxelinux menu. Ideally, I would like to place 
[tftproot_2] as a folder inside [tftproot_1]:

[tftproot_2]
   |-pxelinux.0
   |-[pxelinux.cfg]
       |-default //(main pxelinux menu)
   |-[tftproot_1]
       |-pxelinux.0
       |-[pxelinux.cfg]
	   |-default // nested config
       |-[boot_screens]
            |-menu.cfg

Then, to have the main menu call the nested pxelinux config I have tried 
to load the nested "default" config, but this does not work because the 
nested default looks for "boot_screens/menu.cfg" which now is 
"tftproot_1/boot_screens/menu.cfg".
Alternatively, I tried to boot the nested pxelinux.0, hoping that it 
would use the nested "default" config, but this didn't work either, 
instead the main config was again loaded.

Modifying the nested default config to include the menu.cfg with the 
nested path is not a practical option, because in reality many files are 
included, and I would have to do this each time a new version of 
[tftproot_1] is released.

Specifically for Debian netinst the di-netboot-assistant script 
automatically modifies all the include lines to the correct nested 
paths, so most of my problem is solved.

However, the situation described above is a weakness of pxelinux.

Thanks again for your time,
I hope that the explanations above are clear.

Giannis




On 27/3/2011 8:45 μμ, Gene Cumm wrote:
> On Fri, Mar 25, 2011 at 05:10, Giannis Roussos
> <morpheus at csl.mech.ntua.gr>  wrote:
>> Can you please show again how the preffix is defined?
>
> Unless forced by DHCP option 210, PXELINUX sets the prefix to the
> string before and including the last "/" in the applicable filename in
> the last DHCP response.  This is either the file field or DHCP option
> 67 (if DHCP option 52 bit 0 is asserted; 1 or 3).
>
> It appears that this may not be entirely clear in doc/pxelinux.txt.
>


-- 
-
------------------------------------------------------------------------------
  Giannis P. Roussos
  PhD Student
  Control Systems Lab, Mechanical Eng. Dept.
  National Technical University of Athens
  9 Heroon Polytechniou Str., Zografou
  Athens 15700, Greece

  Tel : ++30-210-772-1726
  e-mail : jrous at mail.ntua.gr
------------------------------------------------------------------------------ 




More information about the Syslinux mailing list