도와주세요!!
글 수 15,339
2004.05.27 12:33:38 (*.110.112.55)
6667
저희는 이런 스크립트를 만들어 쓰고 있읍니다.
[root@ez-x5 bin]$ cat /root/mkflashroot
-------------------------------------------------------------------------
#!/bin/sh
echo "wait about 20sec ..."
cd /
echo "copy /bin"
cp -pfR bin /app
echo "copy /dev"
cp -pfR dev /app
echo "copy /etc"
cp -pfR etc /app
echo "copy /home"
cp -pfR home /app
echo "copy /lib"
cp -pfR lib /app
echo "copy /root"
cp -pfR root /app
echo "copy /sbin"
cp -pfR sbin /app
echo "copy /tmp"
cp -pfR tmp /app
echo "copy /usr"
cp -pfR usr /app
echo "copy /var"
cp -pfR var /app
mkdir /app/proc
mkdir /app/mnt
mkdir /app/mnt/nfs
mkdir /app/mnt/cf
mkdir /app/mnt/mmc
echo "mkdir ...done"
cp -f /root/.fstab /app/etc/fstab
cp -f /root/.rc.local /app/etc/rc.d/rc.local
echo "change EZBOOT->set->Kernel Command"
echo " [noinitrd root=/dev/mtdblock2 console=ttyS02,115200]"
echo " "
-------------------------------------------------------------------------
[root@ez-x5 bin]$ cat /root/mkflashroot
-------------------------------------------------------------------------
#!/bin/sh
echo "wait about 20sec ..."
cd /
echo "copy /bin"
cp -pfR bin /app
echo "copy /dev"
cp -pfR dev /app
echo "copy /etc"
cp -pfR etc /app
echo "copy /home"
cp -pfR home /app
echo "copy /lib"
cp -pfR lib /app
echo "copy /root"
cp -pfR root /app
echo "copy /sbin"
cp -pfR sbin /app
echo "copy /tmp"
cp -pfR tmp /app
echo "copy /usr"
cp -pfR usr /app
echo "copy /var"
cp -pfR var /app
mkdir /app/proc
mkdir /app/mnt
mkdir /app/mnt/nfs
mkdir /app/mnt/cf
mkdir /app/mnt/mmc
echo "mkdir ...done"
cp -f /root/.fstab /app/etc/fstab
cp -f /root/.rc.local /app/etc/rc.d/rc.local
echo "change EZBOOT->set->Kernel Command"
echo " [noinitrd root=/dev/mtdblock2 console=ttyS02,115200]"
echo " "
-------------------------------------------------------------------------