[ipxe-devel] Question about DHCP option length
Johannes Thoma
johannes at johannesthoma.com
Thu Feb 13 14:31:04 UTC 2020
Dear iPXE developers,
Am 11.02.20 um 21:08 schrieb Geert Stappers:
> Yes, that is my request: Please report back how it went.
>
[Note: Problem was that the WinDRBD root device was passed
as a DHCP option which cannot exceed 256 bytes]
It went well. What I did is serve the iPXE client a script
via http. My DHCP server only contains a filename option
that tells iPXE to load the script from that URL (btw. I
didn't find information about how to serve a script (by
passing a filename parameter via DHCP) on
https://ipxe.org/scripting, but it was pretty obvious how
this is done).
DHCP entry is now:
filename "http://192.168.56.102/boot42.ipxe";
where boot42.ipxe is a static file on that server:
#!ipxe
echo "boot42.ipxe ..."
set windrbd-root drbd:resource=windows10-boot;protocol=C;this-node-id=2;node2.address=0.0.0.0:7695;node2.volume1.minor=42;node2.hostname=windows;node1.hostname=johannes-VirtualBox;node1.address=192.168.56.102:7695;timeout=60;ping-timeout=30;ping-int=10;connect-int=20;
sanboot http://192.168.56.102/cgi-bin/drbd.cgi?DRBD_MINOR=42
where the windrbd-root now can have more than 256 bytes. Problem solved.
Note that I also had to patch iPXE to support WinDRBD (we have to pass
the windrbd-root parameter via ACPI to the Windows WinDRBD driver), I
will submit those patches once we reach WinDRBD 1.0.
Thanks for the great work on iPXE,
- Johannes
More information about the ipxe-devel
mailing list