GRUB network boot
Ramon van Handel
vhandel at chem.vu.nl
Thu Sep 2 16:40:06 CEST 1999
>Are there instructions anywhere for how to do a network boot with
>GRUB? I think there is code for it in Dresden's version of GRUB, but
>not in GNU's GRUB, yet.
I've just spent a few days integrating Dresden's netboot stuff into
my heavily hacked version of GRUB, so I do have an idea how this works ;).
The network device is called (nd). So your GRUB config could contain an
entry like this:
title= Netboot Linux
root= (nd)
kernel= /boot/vmlinuz [nfsroot options]
or something similar :)
Network boot works through TFTP/BOOTP. A linux HOWTO that helped me on the
way is the Diskless mini-howto. You need to setup the bootp daemon on your
server using a bootp configuration table, usually in /etc/bootptab. Read
the diskless mini-howto and do man bootp to figure out how this works (do
I need to post an example ?). Then, edit /etc/inetd.conf and uncomment the
lines that look something like this:
tftp dgram udp wait nobody /usr/sbin/tcpd in.tftpd
bootps dgram udp wait root /usr/sbin/in.bootpd in.bootpd
Pitfall: don't forget to give tftpd the directory in which your netboot
files are as a parameter. You will still need to supply the complete
path of that dir in GRUB (the howto's are a bit misleading, they talk
about changing the root dir and stuff like that) but otherwise you would
have to supply a relative path, which GRUB does not support.
Now you should be ready to netboot !
PS, I have heard from people that sometimes the linux bootp daemon doesn't
work. In that case you can try running the dhcp daemon with bootp support.
PPS, I think there's another pitfall -- I haven't been keeping track of
the development of Dresden's GRUB, but if it's similar to the version that
I have at home them it's based on an old version of GRUB, which *does not
compile correctly with the new gas* !!!!!! If you recompile it on an
up-to-date system, GRUB'll crash on boot. So beware.
This same problem occurs with the GRUB dist from uruk.org... GNU GRUB
fixes this.
>This one is even more off-topic, but I'll just mention it quickly: I
>tried last night to install GRUB on an 8.4 GB disc. I know you always
>used to have to make sure that stage2 is in the first 540 MB of the
>disc, but I naively assumed that, since this was modern hardware and
>the latest version of GRUB, and the BIOS was set to LBA mode, I would
>be all right. But it didn't work (something like "Disc geometry
>error"). Do the old restrictions still apply, then?
Was it GNU GRUB ? The last time I tried GNU GRUB (a month ago or so)
LBA mode didn't work for me... while I have a mere 520MB disk, for which
the BIOS DOES support LBA !!!!! On some partitions I got all kinds of
weird geo errors, on others I got corrupted partition information and
stuff like that. I was going to try to debug it but never actually got
around to it...
Ramon
More information about the l4-hackers
mailing list