[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

UMCE linux bootcd scripts



It seemed at the umce.linux.makeworld meeting that it would
be useful to send out more detailed information on the make bootcd
scripts I wrote.  I think this might possibly be of interest to
others as well, so I'm posting this to umce.linux instead.

The directory
	/afs/umich.edu/group/itd/build/mdw/umce/mkbootcd
contains a copy of the files and scripts that I used to make a bootcd.

The file
	/afs/umich.edu/group/itd/build/mdw/umce/mkbootcd/bootcd.T
is not really part of the rest, but is the result of doing
"fsdiff" on the contents of rd-base which is the filesystem
you see after the cd boots.  That includes all 6210 files worth.
This may suffice if you only want a file manifest.

The overall strategy:
	make an bootable iso image (bootcd.iso, size 51 M total.)
		which contains a big ramdisk image (rd-base.bz2) of
			a minimal single user system
			(87 M -> 29 M compressed)
		a small "initrd" image containing just enough intelligence to
			temporarily mount the cdrom and copy the big ramdisk image
			into ram. (34 M -> 14 M compressed)
		and the kernel, syslinux, memtest86, and other small bits.

Adding an extra transcript (or software package) is not very scary:
	edit scripts/command.K
		(for now) to add transcript.
	edit scripts/fixrd30
		to remove any bits of package not needed.

Some of the below could be simplified: at least one step isn't
needed, and other bits should go into radmind transcripts.

Here's the files themselves (about 50):
	initrd.scripts/etc/modules.conf
	initrd.scripts/linuxrc
	initrd.scripts/linuxrc.ask
	initrd.scripts/linuxrc.conf
	initrd.scripts/loadmodules
		mostly scripts that go into initrd.img
	rd-base.scripts/etc/network
	rd-base.scripts/etc/rc.d/init.d/loadmodules
	rd-base.scripts/usr/sbin/autopartition
	rd-base.scripts/usr/sbin/justradmin
	rd-base.scripts/usr/sbin/lindisks
	rd-base.scripts/usr/sbin/master
	rd-base.scripts/usr/sbin/setupethernet
		mostly scripts that go into rd-base
	scripts/,chroot
		test: use chroot to emulate rd-base runtime environment
	scripts/mkall
		top level "make everything" script.
	scripts/genrdbase
		run radmind to populate rd-base with 400 M of stuff.
		For various reasons uses locally provided command.K
		instead of what the server gave.
	scripts/command.K
		list the transcripts ACTUALLY used to make the cd.
		(must be subset of what's really in radmind.
		With slight change can just use what's in radmind.)
	scripts/fixrdbase
		run fixrd10 through fixrd90
	scripts/fixrd10
		make a few necessary files (could be in radmind)
	scripts/fixrd15
		copy a few bits from rd-base into c before they disappear.
	scripts/fixrd20
		run man pages through catman; make result work.
	scripts/fixrd30
		remove a *bunch* of stuff.
	scripts/fixrd40
		strip every executable and shared file left.
	scripts/fixrd60
		replace passwd, fstab, inittab
	scripts/fixrd70
		NOT NEEDED: analyze library dependencies (turns out
		enough libraries are needed that this saves no space.)
	scripts/fixrd80
		copy stuff from rd-base.scripts
	scripts/fixrd85
		NOT DESIRABLE: do evil things with certs.  Future
		boot cds aren't supposed to have any certs in the
		first place, so YOU don't want this.
	scripts/fixrd90
		edit discover's file list because kernel changed.
	scripts/geninitrd
		initialize initrd, copy files from rd-base
	scripts/fixinitrd
		run fixinit10, fixinit20
	scripts/fixinit10
		copy subset of kernel modules into initrd, run depmod
	scripts/fixinit20
		copy discover into initrd
	scripts/help-fixrd20
	scripts/help-fixrd70
	scripts/initrd.files
		list of files copied from initrd to rd-base
	scripts/mkbackup
		make copy of all these scripts
	scripts/mkinitrd
		make c/initrd.img using data from initrd.dir
	scripts/mkrdbase
		make c/rd-base.bz2 using data from rd-base
	scripts/mkcd
		make iso filesystem using contents of c
	scripts/modmk
		analyze kernel module dependencies, find
		those that could identify networking.
	tools/dash.tar
		because bash is a pig
	tools/memtest.tar
		memory test, probably requires vga

If you want a copy of the actual bootcd, send me mail and cc mjsager.
I have some small edits to the above, but I hope to entice mjsager
to use this for the next real distribution bootcd.

-Marcus