tftpboot-setup.txt 3.2 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105

These are the files/directories needed for PXE booting.


	This file

	kernel/MFS for a PXE-booted memory based FreeBSD system.
	We use this MFS for creating disk images and general maintenance
	tasks on a node (e.g., when the node's disk is scrogged).  The
	MFS contains a pretty small set of utilities.

	kernel/MFS for a PXE-booted memory based FreeBSD system.
	This MFS is considerably smaller than the "freebsd" one.  It is
	used to reload node disks with frisbee.  Since it may be loaded
	simultaneously by many nodes to reload their disks, we wanted
	this to be as small as possible.  Not intended as an interactive
	environment, its rc.local script invokes frisbee and then reboots.

	kernel/MFS for a PXE-booted memory based FreeBSD system.
	A specialized version of the frisbee MFS for loading on nodes
	which are not yet part of Emulab.

	The standard PXE-booted startup.  Loaded by every node whenever
	they reboot.  It is a specialized, stripped-down version of the
	FreeBSD boot loader.

	Programs downloaded by PXE in order to bootstrap the various
	MFSes.  These are not variants of "pxeboot" above but are each
	just versions of the standard FreeBSD pxeboot with a path changed
	to reflect the appropriate "root" directory.


If you are reading this file, then I guess you have succeeded in unpacking
the tarball.  Hopefully, you have unpacked it into /tftpboot.  If not, go
do that now, I'll wait...

...ok.  Things will work with what you have just unpacked, but to make them
more efficient, you should go into the various */boot directories and run the
prepare script there.  All this script does is create gzip'ed version of the
various files that are needed to bootstrap the MFS-based system.  This will
speed up the boot process considerably:

	foreach d in (freebsd frisbee freebsd.newnode)
	(cd $d/boot ; sudo ./prepare)


If you want to see what is in one of the MFSes or otherwise customize it,
you simply mount the MFS as a filesystem.  This takes two steps in BSD:
associating a "virtual disk" with the file and then mounting that disk,
e.g. as root:

	vnconfig vn0 /tftpboot/frisbee/boot/mfsroot
	mount /dev/vn0c /mnt

When you are done, just unmount the filesystem and rerun the prepare

	umount /dev/vn0c
	cd /tftpboot/frisbee/boot; ./prepare

If you aren't going to do any more mods for a while, then you can
unconfigure the disk as well:

	vnconfig -u vn0

though this isn't necessary in order for your changes to make it into
the MFS that is downloaded (it *is* essential that you rerun the prepare
script above or else the node will continue to download mfsroot.gz instead
of your updated mfsroot).

Note that you may have to create vnode-disk devices in /dev:

	cd /dev; ./MAKEDEV vn0 vn1


The kernel which drives the MFS-based system is not part of the MFS itself.
So to install a new kernel, you do not have to do the MFS nonsense above.
You just have to stick your kernel into /tftpboot/blah-blah/boot, ala:

	cp kernel /tftpboot/frisbee/boot
	cd /tftpboot/frisbee/boot; ./prepare

Again, it is important to rerun prepare.