Enable iso-scan in BackTrace 4 Live CD Image

* Update *
There is a more elegent way to fix this problem:
Since the command mkiniramfs-script copies required file from the system, we just need to find the package that contains '20iso_scan', 'lupin-helpers'. Using the command 'dpkg -S', we can find that these to files belongs to the package: lupin-casper.

After chroot into the livecd environment:
aptitude install lupin-casper
update-initramfs -u
exit and copy the initrd.gz to the usb, the iso-scan is enabled!

Doing it in the hard way

* First, we need two files: lupin-helpers 20iso_scan from ubuntu livecd
mount -o loop ubuntu-livecd.iso /mnt
cp /mnt/casper/initrd.lz ~
umount /mnt
cd ~
mkdir test
cd test
gzip -dc ../initrd.lz | cpio -imvd --no-absolute-filenames
cp script/lupin-helpers script/casper-premount/20iso_scan ~
cd ~
rm -rf test initrd.lz
* Second, you need can add this to bt4 customization script, or either run it in the terminal.
echo "[*] Adding iso-scan script to initrd..."
INITRDS='initrd.gz initrd800.gz initrdfr.gz'
for i in $INITRDS; do
  mkdir tmp
  cd tmp
  gzip -dc ../extract-cd/boot/$i | cpio -imvd --no-absolute-filenames --quiet
  cp ../20iso_scan scripts/casper-premount
  cp ../lupin-helpers scripts
  rm ../extract-cd/boot/$i
  find . | cpio --quiet --dereference -o -H newc | gzip -9 > ../extract-cd/boot/$i
  cd ..
  rm -rf tmp

* Done. You can now use iso-scan/filename in cmdline.



成功安裝Vista & Ubuntu Linux 8.04 LTS 雙系統!!!