|
发表于 2003-11-4 11:35:04
|
显示全部楼层
coyote linux可以从软盘引导,也实现了从硬盘上引导,但我更愿意从光盘上引导。因为光盘不容易坏,启动速度比软盘快,配置一般一次设置终生使用,即使更改配置也大不了重刻一张,CD-R白盘3元而已,而且在平时使用过程中光驱没有读盘,耗电也极少,同时可以让那些坏了软驱坏了硬盘的老机器也能作软件路由器。
以下是我从网上找来的。有两个方法。不过两个方法提到的文件root.linuxrcw在coyotelinux2.x的root.tgz中没有找到。不知大家没有试过,或者有更好的办法。希望大家交流一下
Booting Coyote Linux from a CD-ROM
Overview
This is an involved process and requires some hacking on a full Linux system to create the boot CD. Something to keep in mind is that the configuration of such a system cannot be updated; you are creating a CD-ROM, as in "Read Only Memory". All of your configuration options, port-forwarding, or script modifications must be completed and tested before you create the CD. You don't need an IDE-enabled kernel to make this work, as it merely takes advantage of the BIOS-enabled ability of many computers to boot from a CD.
Following are two sets of instructions. The first set were provided for CL1.x; they have not been tested (to my knowledge) with CL2.x. The second set were written for CL2.
--------------------------------------------------------------------------------
Method 1
Mount the floppy on the machine with the CD burner. Start from your home directory; this example uses /home/fred.
mkdir cdcoyote
cp /mnt/floppy/* cdcoyote
mkdir cdcoyote/root
cd cdcoyote/root
tar -xzvf ../root.tgz
Edit linuxrc and continue on, but you may want to uncomment DEBUG if you wish, and then continue to this:
MNT="/var/lib/lrpkg/mnt"
qt mkdir $MNT
becomes this:
MNT="/var/lib/lrpkg/mnt"
#qt mkdir $MNT
change this:
qt mount -o ro -t $FSTYPE /dev/$DEVICE $MNT
ln -sf $DEVICE /dev/boot
to this:
#qt mount -o ro -t $FSTYPE /dev/$DEVICE $MNT
ln -sf $DEVICE /dev/boot
and this:
qt umount /proc
qt umount $MNT
becomes this:
qt umount /proc
#qt umount $MNT
Save it.
cd var/lib/lrppkg
mkdir mnt
cd mnt
copy all the ROOTMAP tgz files here (those in syslinux.cfg LRP=.......
copy all tgz files listed in the packages file here.
cd /home/fred/cdcoyote/root
tar -czvf ../newroot.tgz *
cd ../
check the permissions on the old root.tgz and make newroot.tgz match'em then
rm root.tgz
mv newroot.tgz root.tgz
rm the tgz files that you moved to lrppkg/mnt from /home/fred mkdir cdimg
mkdosfs -C 288.img 2880
mount -t msdos -o loop 288.img cdimg
cd cdimg
cp /home/fred/cdcoyote/* .
cd ../
syslinux 288.img
umount cdimg
mv 288.img cdimg
mkisofs -b 288.img -c boot-catalog -o /tmp/coyote.iso cdimg
cdrecord speed=4 dev=0,0,0 /tmp/coyote.iso
Most of this was listed in a mini howto for LRP (password required).
--------------------------------------------------------------------------------
Method 2
Author: Tiago Ratto
Date: 10-10-03 15:41
What do you need ?
A WORKING Coyote Linux 2.x floppy
1 Computer running WIndows
1 Computer running Linux (Windows with Cygwin might work, not tested)
1 CD-R Drive
1 (or more) CD-R media
WinImage (to create and change disk images)
optional: Bochs (to test the images you've made)
BCD, MultiMemDisk (www.nu2.nu - Thanx Bart)
-1st Step
[Location: Windows]
So, you've already created your Coyote linux ok ? Run WinImage and make a disk image of your disk, save the image as non-compressed format.
- 2nd Step
[Location: Linux/Cygwin]
Now create a folder in your hard drive and extract all the tgz's inside. Create another folder inside the folder you've created named root and extract the root.tgz inside. Move the others tgz's files to the folder root. Now go tho to root/var/lib/lrpkg/ and edit the root.linuxrc file. Now change the following lines:
[126]
if [ -f $MNT/$f.tgz ]; then
to:
if [ -f /$f.tgz ]; then
[131]
zcat $MNT/$f.tgz | qt tar -x
to:
zcat /$f.tgz | qt tar -x
[154]
if [ -f $MNT/$f.tgz ]; then
to:
if [ -f /$f.tgz ]; then
[156]
qt zcat $MNT/$f.tgz > /dev/null
to:
qt zcat /$f.tgz > /dev/null
Now extract the file syslinux.cfg from the image and open it. Change the parameter:
boot=/dev/fd0
to:
boot=/
- 3rd Step
[Linux/Cygwin]
Now enter the root folder and compress all the files using tgz-like tool creating a new root.tgz.
[Windows]
After all that put the files you'd changed back into the image file using the WinImage and save it. And copy it to the cds/multi_memdisk/disk1/isolinux folder on the MultiMemDisk folder. Go to the MultiMemDisk folder and enter the cds/multi_memdisk/disk1/isolinux and alter the isolinux.cfg and the bootmsg as you like. After that go back to the MultiMemDisk folder and type "run" to burn your CD-R, follow the intructions and all should be fine !!! :-))))
PS1: If you are using WindowsXP generate a image file with de MultiMemDisk and burn it to the CD using a Nero-like software.
Credits, Licenses, Sources and Documentation
Coyote Linux - Vortech Consulting - http://www.coyotelinux.com
Coyote Linux FAQ - http://rzero.com/coyote/faq.html
BCD - http://www.nu2.nu
Compiled by Todd VerBeek. |
|