Posted to a Web discussion forum by:
Eaden McKee
Opentec Ltd
eaden@opentec.co.nz
Based on
http://www.linuxtag.org/cgi-bin/yabb/YaBB.pl?board=knoppix-en;action=display;num=1025275154
These are some instructions and tips for those wanting to
remaster your own
version of knoppix. You don't even need a CD writer to test
it.
* You need a swap partition of at least 1 gig, I haven't done
this with
less than 2GB of swap so I'm not sure if you need 2gig or 1
gig.
* You will also need 3 Gig free on a disk
* Boot with Knoppix CD. Open Root shell. (All commands below are run from a Root shell.)
* Make 2 directories on a partition with 3 gig free, master and source. (We'll call them /mnt/source and /mnt/master.)
mkdir /mnt/source/KNOPPIX
cp -Rp /KNOPPIX/* /mnt/source/KNOPPIX
mkdir /mnt/master/KNOPPIX/
cp /cdrom/KNOPPIX/boot.img /mnt/master/KNOPPIX/
* chroot /mnt/source/KNOPPIX/
You are now "chrooted" in the knoppix source directory.
* mount -t proc /proc proc
edit /etc/resolv.conf to add your name server and check that you
are
connected to the internet (ping google.com).
now you can run apt-get update, and install other programs.
if you want to install other programs you will need to remove
some programs
too. edit what you will and make the changes you want ( e.g. kde
defaults
etc. ) the kde defaults for user knoppix are stored in
/etc/skel
Once all the changes are made, run the following:
apt-get clean ( removes downloaded packages)
updatedb ( so `locate` works )
umount /proc
Then press Ctrl+D to leave being chrooted.
For the sake of cleanliness, rm the .bash_history files and other unnecessary files that were created in the chroot environment. (Logs, etc.)
To make the "KNOPPIX" file ( the compressed file ) run
mkisofs -R -l -V "KNOPPIX iso9660 filesystem" -hide-rr-moved
-v \
/mnt/source/KNOPPIX | create_compressed_fs - 65536 > \
/mnt/master/KNOPPIX/KNOPPIX
Be warned that this will take a tremendous amount of RAM + swap.
Now you can either make the final ISO image for burning or you can test it by symlinking the KNOPPIX directory in a root directory of a partition e.g.
cd /
ln -s /mnt/master/KNOPPIX KNOPPIX
then you can make a boot floppy :
dd if=/mnt/master/KNOPPIX/boot.img of=/dev/fd0
and boot off that, _without the cd in the drive_, when looking for the CD it will look for a Directory called "KNOPPIX" on /dev/hda1 a2 a3 b1 b2 etc., etc. if it finds one then it will say "accessing CD on /dev/hda1" and use that as the CD.
After this you are ready to make the final iso image to burn so run the following:
mkisofs -l -r -J -V "KNOPPIX-your_name" -hide-rr-moved -v -b
\
KNOPPIX/boot-en.img -c KNOPPIX/boot.cat -o
/somewhere/knoppix-cd.iso \
/mnt/master
make sure it isn't bigger than 700MB (or 650 if you want to use
the
74 minute cdroms).
ls -lh /somewhere/knoppix-cd.iso
then burn it !
That's it.
Also, the boot.img is made with syslinux, you can read how to
make your own
boot screen in "man syslinux".
I hope these are accurate, please e-mail me if I have missed anything.