iPXE discussion forum
IPXE Version - Printable Version

+- iPXE discussion forum (https://forum.ipxe.org)
+-- Forum: iPXE user forums (/forumdisplay.php?fid=1)
+--- Forum: General (/forumdisplay.php?fid=2)
+--- Thread: IPXE Version (/showthread.php?tid=7015)

IPXE Version - ymolinet - 2013-08-19 21:51


I'm need to detect also the version of iPXE with 'avoid loop'. If the version is to old, call undionly.kpxe as another pxe rom.

if exists user-class and option user-class = "iPXE" {
filename "http://my.web.server/real_boot_script.php";
} else {
filename "undionly.kpxe";

Thanks for helps,

IPXE Version - ymolinet - 2013-08-20 16:53

Hi all,

I'm using network cards that contains an old IPXE Version (command menu is not supported). If I manage the DHCP by user-class detection, it's not working for this network card.

Is it possible to detect the IPXE Version in the if statement (ISC-DHCP) ?

Thanks for help,

RE: IPXE Version - robinsmidsrod - 2013-08-22 09:28

You can use feature detection to make this work. You can see how I've done it with ISC dhcpd here: https://gist.github.com/robinsmidsrod/4008017

RE: IPXE Version - ymolinet - 2013-08-22 09:53

So, just test if the PXE module is available ? that right's ?

RE: IPXE Version - robinsmidsrod - 2013-08-22 10:03

Lines 10-13 of ipxe-green.conf contain the feature detection parts, and if you include a feature there that your burned-in ipxe version do not support (like menu) then it should chainload the proper version. This is like an extended version of the typical "break the eternal loop" chainloading example on the wiki.

RE: IPXE Version - ymolinet - 2013-08-22 16:51

I see that IPXE options contain ipxe.version, so I can do a test on this option to determine the current version of the IPXE ROM.
But IPXE Version string is like "1.0.0+ (ca319)" so I could not determine if this version is older than "1.0.0+ (6d72b4)". I could only determine if string are not equal (not like a simple number : upper or greater)

In my project, Debian 7.10 netboot failed during boot with an old IPXE ROM, but not with the "on-line" version (http://boot.ipxe.org/undionly.kpxe) it's working as fine. So my goal is to determine if the IPXE Rom is not so older to boot some OS.

RE: IPXE Version - robinsmidsrod - 2013-08-23 13:40

iPXE scripting doesn't have a command to test for bigger/lower number, only existance and equality. The version variable is also quite recent, so older versions won't have it. Your best bet is to use feature detection or forcibly load a new version of ipxe for all clients, including the ones that have a recent iPXE ROM burned in.

RE: IPXE Version - ymolinet - 2013-08-23 13:42

ok. Thanks for help.