69486c4f58
If iPXE boot failed, then make sure the 'reboot' action is really executed. The problem with 'prompt --timeout...' is that this command will fail if no key is pressed. However, iPXE exits immediately if one of the command fails so the 'reboot' action was never executed and the node was stuck in the following unbootable state. boot.ipxe : 395 bytes [script] /pxelinux.cfg/52-54-00-23-e4-c2... No such file or directory (http://ipxe.org/2d0c613b) /pxelinux.cfg/default... ok Configuring (net0 52:54:00:23:e4:c2).................. Error 0x040ee119 (http://ipxe.org/040ee119) Could not boot: Error 0x040ee119 (http://ipxe.org/040ee119) PXE boot failed. No configuration found for MAC 52:54:00:23:e4:c2 Press any key to reboot... Could not boot image: Connection timed out (http://ipxe.org/4c22e035) No more network devices Change-Id: If4b2bab25bcfe8da0a64ee9cc1659580aec9776a
18 lines
405 B
Plaintext
18 lines
405 B
Plaintext
#!ipxe
|
|
|
|
isset ${mac:hexhyp} && goto boot_system ||
|
|
chain ipxe.pxe
|
|
|
|
# load the MAC-specific file or fail if it's not found
|
|
:boot_system
|
|
chain pxelinux.cfg/${mac:hexhyp} || goto inspector_ipa
|
|
|
|
:inspector_ipa
|
|
chain pxelinux.cfg/default || goto error_no_config
|
|
|
|
:error_no_config
|
|
echo PXE boot failed. No configuration found for MAC ${mac}
|
|
echo Press any key to reboot...
|
|
prompt --timeout 180 || reboot
|
|
reboot
|