Thursday 10 June 2010

boot iso with pxe and grub4dos

following this guide [http://diddy.boot-land.net/grub4dos/files/pxe.htm] with small modification

I use tftpd 3.35 [http://tftpd32.jounin.net/tftpd32_download.html]

tftpd32 program to
C:\tftpd32\
and create
C:\tftpd32\root\

copy grldr to c:\tftpd32\root\ , the same as the guide

Don't create C:\tftpd32\root\menu.lst\
it is now /menu/ or grldr can read or search for /menu.lst file


tftpd32 - settings
 - Base Directory set to the root folder we created earlier (C:\tftpd32\root)
 - only need dhcp and tftp server
 - Ensure that Allow '\' As virtual root is enabled - this will allow file/folder paths to treat C:\tftpd32\root\ as / (e.g. entering chainloader /pxelinux.0 from the Grub4dos command line will chainload C:\tftpd32\root\pxelinux.0.)
 - bind tftp dhcp address, I set it to prevent the error "request 2 not processed" (set it to the interface which is directly connected to the pxe client)


dhcp - settings
 - IP pool , the same subnet to the pxe server
 - size of pool , easy
 - boot file , grldr [1][2]
 - mask , set it to the same subnet to the pxe server will be ok

now copy grldr , menu.lst , the iso file to C:\tftpd32\root

I boot geexbox , so , in my menu.lst
#start
title pxe geexbox
#(fd33) is equivalent to (pd) or it can be / , because we enabled virtual root in tftpd
map --mem --heads=0 --sectors-per-track=0 (pd)/geexbox-r8328.iso (hd32)
map --hook
chainloader (hd32)
boot
# also
title Boot slitaz-3.0.iso

map --mem --heads=0 --sectors-per-track=0 (fd33)/slitaz-3.0.iso (0xff)
map --hook
chainloader (0xff)
boot
# also
title Boot slitaz-4.0.iso
map --mem --heads=0 --sectors-per-track=0 (pd)/slitaz-4.0.iso (0xff)
map --hook
chainloader (0xff)
boot
#end


and everything is the same as grub / grub4dos then

[1] [http://gna.org/projects/grub4dos/]
[2] [http://code.google.com/p/grub4dos-chenall/]

3 comments:

Medox said...

Nice post.
Thanks.

Anonymous said...

Hey, dude.
I'm kind of a noob, so please bear with me. I've got SOME understanding of linux and very little about bootloaders.

I've been looking for a very long time for such an option to boot via pxe from an iso.

I've tried several options, until I got here.
I tried your version, with the simple options from here:
http://www.themudcrab.com/acronis_grub4dos.php
I need to do it like this, because some of the computers I'm trying to boot do not have enough memory to load the whole windoze iso file into memory, so I have to get the iso mounted as a virtual cd, meaning I can't use the --mem option. (or memdisk for that matter)
So, when I try to boot the .iso file I want, I get the error:
Error 15: File not found
If I try to boot the other pxelinux.0, I get this one:
Error 13: Invalid or unsupported executable

So please, can you help me get the hang of it?

I am using:
tftpd32 v 3.50, configured correctly (I am sure of it because if I pxe-boot the pxelinux.0, it works flawlessly)
grub4dos-4.4.4-2009-03-31_(official_release)

here's how my menu.lst looks like:
timeout 30
default 0

title Windoze XP Install ISO
map (hd0,0)/wxl.iso (hd32)
map --hook
chainloader (hd32)
boot

title Other stuff
kernel /pxelinux.0
initrd /pxelinux.0
boot

title Reboot
reboot

title Poweroff
halt

Unknown said...

thx. i have searched such a this good post. ^^

Labels

Search This Blog