- 論壇徽章:
- 0
|
大家都知道SCO OSR55.0.x創(chuàng)建應(yīng)急引導(dǎo)盤時(shí)可以做
boot+root的盤,但是只能用2.88MB的軟盤(/dev/fd0135ds36),所以一直沒有嘗試過。
昨日無事,忽憶起此事,隨試之:
1、在/tmp/boot/目錄下做一空文件,boot288.img(名字任意,boot目錄自建)
2、用marry偽裝成設(shè)備:
a) # cd /dev
b) # mv fd0135ds36 /tmp
c) # mv rfd0135ds36 /tmp
d) # marry -a /tmp/boot/boot288.img
e) # ln /dev/marry/tmp/boot/boot288.img /dev/fd0135ds36
f) # mknod rfd0135ds36 c 76 1(76和1是根據(jù)此時(shí)的fd0135ds36來的)
3、運(yùn)行mkdev fd創(chuàng)建應(yīng)急引導(dǎo)盤。
自然是選boot+root 和 2.88MB大小的設(shè)備了 :)
4、將偽裝的設(shè)備拆下來
a) # marry -d /tmp/boot/boot288.img
b) # mv ......將 mv 到tmp下的兩個(gè)設(shè)備移回來
5、生成可引導(dǎo)的鏡像文件
a) # cd /tmp/boot
b) # vi p.sh ##(創(chuàng)建一SHELL 將生成的img文件[ 小于2949120 Bytes]不足的字節(jié)補(bǔ)齊 [ 2949120 Bytes ] )
######
#! /bin/sh
[ "$#" != "1" ] && exit 2
rm -f boot288a.img
>ext
File=$1
S=`ls -l $File|awk '{print $5}'`
E=`expr 2949120 - $S`
A=1
echo "\033[2J $E"
# echo " $E"
while [ "$A" -le $E ]
do
echo -n "\000" >> ext
echo -n "\033[2;1H $A"
# echo -n "\033[;1H $A"
A=`expr $A + 1`
done
cat $File ext >boot288a.img
## mkisofs -b images/boot/IMGFILE -J -o /c:/IMG.iso -r -V "VOL_Flag" /Path
######
# p.sh boot288.img;
c) # mkisofs -b boot288a.img -J -o /tmp/boot288.iso -r -V "SCO_2.88MBGeneric" /tmp/boot
6、將/tmp/boot288.iso傳到WIN系統(tǒng)刻成光盤就OK了。
-----------------------------------@_@----------------------------------
注:你可以在/tmp/boot下加許多東東,要不然刻成的光盤就太浪費(fèi)了,只有兩MB哈。
問題:用這張光盤引導(dǎo)完系統(tǒng)后,光盤沒辦法掛上使用,可惜哈。
解決方案:將/etc/fscmd.d/HS整目錄復(fù)制到對(duì)應(yīng)位置就OK了。
如果你還想讓應(yīng)急盤支持ISO9660文件系統(tǒng),那就把/etc/fscmd.d/ISO9660也復(fù)制過來好了......,還有RCKRDG什么的。試吧,成功屬于你。(在這張軟件中可以加符號(hào)鏈接的目錄,指向光盤對(duì)應(yīng)目錄就可以用了)
![]()
贈(zèng)送:可以加 網(wǎng)絡(luò)功能 和 vi 在鏡像上,方法如下:
Do you want a shell escape to place extra files on the root filesystem?(y/n)回答y,你將會(huì)看到如下信息:
You can copy files into/mnt to customize your root filesystem floppy?
After you finish,type “exit 0”to continue?
You have n free blocks(512 bytes each)available on the floppy?
此時(shí),命令提示符是<bootroot>;
在<bootroot>提示符下用下列命令復(fù)制網(wǎng)絡(luò)服務(wù)文件和vi的支持功能:
cp/etc/services /mnt/etc/services
cp/etc/tcp mnt/etc/tcp
cp/etc/slink /mnt/etc/slink
cp/etc/ifconfig /mnt/etc/ifconfig
cp/etc/inconfig /mnt/etc/inconfig
cp/bin/who /mnt/bin/who
cp/bin/ps /mnt/bin/ps
cp/usr/bin/telnet /mnt/usr/bin/telnet
cp/usr/bin/rlogin /mnt/usr/bin/rlogin
cp/usr/bin/ftp /mnt/usr/bin/ftp
cp/usr/bin/vi/ mnt/usr/bin
mkdir -p /mnt/usr/lib/terminfo/a
cd /usr/lib/tcrminfo/a
cp ansi /mnt/usr/lib/terminfo/a
exit 0
最后:燒吧,燒吧,刻成碟了
![]()
再最后我也敲累了 :)
![]()
樹偉 于 2004.02.22下午
shuweich@163.com
QQ:1502384
----------------------------------------------------------------------------------
這兩天總算有點(diǎn)時(shí)間了,哎,忙瘋我啦!!! ):
我把SCO應(yīng)急引導(dǎo)(通用的和特定的核心),SCO安裝盤,還有WIN98SE安裝盤刻到一張CD上了,實(shí)現(xiàn)了多重引導(dǎo).
可以在光盤引導(dǎo)后顯示一菜單:
1- SCO OSR 5.0.5 Install
2- Start computer with SCO OSR 5.0.5 Generic Kernel
3- Run MS-Windows 98 SE setup
4- Boot with SCO OSR 5.0.5 Big Image (4MB Ramdisk)
c- Quit to command prompt
r- Reboot
a- Boot from floppy
h- Boot first harddisk
這樣就可以提著一張安裝盤和一張工具盤到處跑了.
目前只刻了幾個(gè)引導(dǎo)文件,實(shí)現(xiàn)了多引導(dǎo);
下一步加安裝文件到光盤里,嘗試一下用這張盤裝裝系統(tǒng).
以上內(nèi)容本人于2004.03.09添加
本文來自ChinaUnix博客,如果查看原文請(qǐng)點(diǎn):http://blog.chinaunix.net/u/17144/showart_1146101.html |
|