One of the downsides of leaving the linux live scripts and moving to non lzma enabled squashfs, is that we loose the wonderful and convenient setup for modifying the BackTrack LiveCD on our own. We use to be able to pop in a LZM file into the “optional” directory, and that’s it – but no more.
Actually, customizing a casper based ISO isn’t that difficult, just different. I put up this quick guide on how to edit your own livecd and add various tools, drivers and scripts to it.
First, install BT4 and get a copy of the BT4 iso. As root, create the build environment, and chroot into it:
mkdir -p /root/BUILD
mv bt4.iso /root/BUILD
cd /root/BUILD/
mkdir mnt
mount -o loop bt4.iso mnt/
mkdir extract-cd
rsync --exclude=/casper/filesystem.squashfs -a mnt/ extract-cd
mkdir squashfs
mount -t squashfs -o loop mnt/casper/filesystem.squashfs squashfs
mkdir edit
cp -a squashfs/* edit/
cp /etc/resolv.conf edit/etc/
cp /etc/hosts edit/etc/
cp /etc/fstab edit/etc/
mount --bind /dev/ edit/dev
chroot edit
You are now in the livecd environment, and can alter the build in any way you like. This is where you add your scripts, drivers and whatnots. At minimum, i’de suggest updating your iso with the current repo, which can be done with :
apt-get update
apt-get upgrade
apt-get clean exit
Once all the changes are made, close the build and create an iso out of it :
umount edit/dev
chmod +w extract-cd/casper/filesystem.manifest
chroot edit dpkg-query -W --showformat='${Package} ${Version}n' > extract-cd/casper/filesystem.manifest
REMOVE='ubiquity casper live-initramfs user-setup discover xresprobe os-prober libdebian-installer4' for i in $REMOVE do sed -i "/${i}/d" extract-cd/casper/filesystem.manifest-desktop done
cp extract-cd/casper/filesystem.manifest extract-cd/casper/filesystem.manifest-desktop sed -i '/ubiquity/d' extract-cd/casper/filesystem.manifest-desktop rm -rf extract-cd/casper/filesystem.squashfs mksquashfs edit extract-cd/casper/filesystem.squashfs rm extract-cd/md5sum.txt (cd extract-cd && find . -type f -print0 | xargs -0 md5sum > md5sum.txt) find /boot /usr/lib/grub/ -iname 'stage2_eltorito' -exec cp -v {} extract-cd/boot/grub \; cd extract-cd mkisofs -b boot/grub/stage2_eltorito -no-emul-boot -boot-load-size 4 \ -boot-info-table -V "BT4" -cache-inodes -r -J -l -o ~/bt4-mod.iso .
相关推荐
Ubuntu是从光盘引导进入Live版,如果安装则需要开启安装向导从光盘安装。这么做的主要目的是让用户体验完Ubuntu的魅力之后,自愿来安装。但是,一些开始就决定安装的用户就会觉得有一些不便。文庄就是从这个角度考虑...
通过liveCD进行ubuntu启动修复.doc
ubuntu livecd自动安装,ubuntu光盘自动安装的isolinux.cfg文件
ubuntu引导修复——使用LiveCD更新UbuntuGrub引导 。
使用Ubuntu LiveCD安装grub 因为安装windows,或者不小心删除/改变了mbr,都有可能导致启动时看不到grub的引导菜单或者提示出错,下面是恢复的办法 (写于Ubuntu下,但应该可适用于其它系统)
tux2live可将常用LINUX定制成LIVECD版,比如UBUNTU等
定制Linux LiveCD的研究与实现.pdf
在lfs基础上制作liveCD文档 如有问题,请指点.
How To 用 ubuntu Desktop LiveCD测试新电脑
WIN 7 LIVE CD 2010 Part1 WIN 7 LIVE CD 2010 Part2 带上一张光盘,就可以在其它计算机上使用Windows 7了。 Windows 7的Live CD让您可以快速启动计算器工作,并不需要安装在硬盘上运行的Windows 7 -操作系统的Live...
ubuntu-18.04.4
Ubuntu12.04LTS下定制自己的Ubuntu Live CD的方法,适合新手使用。
WIN 7 LIVE CD 2010 Part1 WIN 7 LIVE CD 2010 Part2 带上一张光盘,就可以在其它计算机上使用Windows 7了。 Windows 7的Live CD让您可以快速启动计算器工作,并不需要安装在硬盘上运行的Windows 7 -操作系统的Live...
详细描述了如何使用UltraISO制作u盘启动的ubuntu步骤
利用live cd升级联想服务器网卡等适配器的固件
制作Fedora Linux Live CD指南。
制作U盘Live CD启动 一种很好用的工具