Remaster your own live installer, live iso

works with ubuntu too... Ubuntu Live CD Customization


Fetch your favorite iso, in the following examples we will take puredyne-911-carrot_and_coriander iso to show that this procedures can apply to a lot of different isos/systems.

The basic procedure is simple:

Just to be sure not to have locales problems during installation of new packages export 2 system variables:

export HOME=/root
export LC_ALL=C

Chroot:

sudo mount - o loop puredyne.iso /mnt
mkdir extract-cd
rsync --exclude=/live/filesystem.squashfs -a /mnt/ extract-cd

sudo mount --bind /dev/ edit/dev
sudo chroot edit
mount -t proc none /proc
mount -t sysfs none /sys
mount -t devpts none /dev/pts
sudo unsquashfs /mnt/live/filesystem.squashfs
sudo mv squashfs-root edit

This is for some reasons connected with a couple of dbus bugs, so I'll go through it(as root):

dbus-uuidgen > /var/lib/dbus/machine-id

dpkg-divert --local --rename --add /sbin/initctl
ln -s /bin/true /sbin/initctl

When you want to remove packages remember to use purge I investigated a bit the matter, not enough to know whats going on but enough to know is a good practice.

Once in the chroot start poking:

# refresh your list
apt-get update
# some must have
apt-get install htop modconf
# some multimedia 
apt-get install cinelerra sox twolame mpeg2dec a52dec libsox-fmt-all a52dec darkice darksnow

Closing

aptitude clean
rm -rf /tmp/* ~/.bash_history
rm /etc/resolv.conf
rm /var/lib/dbus/machine-id
rm /sbin/initctl
dpkg-divert --rename --remove /sbin/initctl
dpkg -l > packages.txt
umount /proc
umount /sys
umount /dev/pts

sudo umount edit/dev
sudo mv edit/packages.txt cdextract