[gPXE] pxe boot and sanboot
Stefan Hajnoczi
stefanha at gmail.com
Sat Jan 30 14:16:15 EST 2010
2010/1/30 Aclhk Aclhk <aclhkaclhk at ymail.com>
> gpxe commands (sanboot) are not executed. I need to press ctrl-B to manually execute the comands. I want to boot gpxe and automatically run "set keep-san 1", "sanboot ....."
>
> i do not know why it suggested filename= "".
> http://etherboot.org/wiki/sanboot/iscsi_boot
Here are the stages in your boot process:
PXE -> undionly.kpxe -> iSCSI Centos 5.4
First, your DHCP server must give the "undionly.kpxe" filename in
order to load gPXE. This is why you have the following line in your
DHCP configuration:
filename "./gpxe/undionly.kpxe";
Then the DHCP server must give the "iscsi:192.168.123.1::::iscsi-gpxe"
root-path to gPXE in order to iSCSI boot Centos 5.4. This is why you
have the following line in your DHCP configuration:
option root-path "iscsi:192.168.123.1::::iscsi-gpxe";
Then gPXE can iSCSI boot Centos 5.4 from your SAN.
To summarize, there are two DHCP requests. The first request must
give the "undionly.kpxe" filename and gPXE will be started. Then gPXE
performs the second DHCP request and should receive the iSCSI
root-path.
I think the problem is that your DHCP configuration sends *both*
filename and root-path together. On the second request, gPXE will see
the "undionly.kpxe" filename and try to load it again...you have an
infinite loop.
The solution to the problem is described on the PXE chainloading page,
which I linked to before:
http://etherboot.org/wiki/pxechaining
Try this DHCP configuration:
if exists user-class and option user-class = "gPXE" {
filename "";
option root-path "iscsi:192.168.123.1::::iscsi-gpxe";
} else {
filename "./gpxe/undionly.kpxe";
}
This configuration should send iSCSI options for a DHCP request coming
from gPXE and a filename for a DHCP request not from from gPXE.
If this does not work, please send the output you see on the screen so
we can tell what is going on. You might want to take a picture, or
even a video, instead of remembering and typing all the messages you
see.
Stefan
More information about the gPXE
mailing list