init.in-milis
This commit is contained in:
parent
46678ba262
commit
c1726f0f40
|
@ -176,17 +176,17 @@ do_mount_in_ram()
|
||||||
}
|
}
|
||||||
|
|
||||||
find_media() {
|
find_media() {
|
||||||
EXPECT_LABEL="nutyxcd"
|
EXPECT_LABEL="milis_calisan"
|
||||||
for SYS in /sys/block/sd* /sys/block/sr* ; do
|
for SYS in /sys/block/sd* /sys/block/sr* ; do
|
||||||
[ "$verbose" == "no" ] || echo "Looking in $SYS for media"
|
[ "$verbose" == "no" ] || echo "Looking in $SYS for media"
|
||||||
if [ ! -d "$SYS" ]; then continue; fi
|
if [ ! -d "$SYS" ]; then continue; fi
|
||||||
DEV=/dev/${SYS##*/}
|
DEV=/dev/${SYS##*/}
|
||||||
LABEL=`dd if=$DEV bs=1 skip=32808 count=32 2>/dev/null`
|
LABEL=`dd if=$DEV bs=1 skip=32808 count=32 2>/dev/null`
|
||||||
if [ ${LABEL} == ${EXPECT_LABEL} ] 2>/dev/null ; then
|
if [ ${LABEL} == ${EXPECT_LABEL} ] 2>/dev/null ; then
|
||||||
ln -s $DEV /dev/nutyx-cd
|
ln -s $DEV /dev/cdrom
|
||||||
mkdir -p /media/cdrom 2>/dev/null
|
mkdir -p /media/cdrom 2>/dev/null
|
||||||
[ "$verbose" == "no" ] || echo "mount -n /dev/nutyx-cd /media/cdrom"
|
[ "$verbose" == "no" ] || echo "mount -n /dev/cdrom /media/cdrom"
|
||||||
mount -n /dev/nutyx-cd /media/cdrom
|
mount -n /dev/cdrom /media/cdrom
|
||||||
[ -d /media/cdrom/depot ] && echo $DEV > /tmp/depot
|
[ -d /media/cdrom/depot ] && echo $DEV > /tmp/depot
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
|
@ -197,7 +197,7 @@ MainLoop(){
|
||||||
while [ ! -f /root/boot ];
|
while [ ! -f /root/boot ];
|
||||||
do
|
do
|
||||||
[ "$verbose" == "no" ] || echo "Launch /etc/rc.d/init.d/milis-kur ..."
|
[ "$verbose" == "no" ] || echo "Launch /etc/rc.d/init.d/milis-kur ..."
|
||||||
/etc/rc.d/init.d/setup-nutyx || problem
|
/etc/rc.d/init.d/milis-kur || problem
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -255,9 +255,9 @@ if [ -n "$rootdelay" ] ; then
|
||||||
sleep "$rootdelay"
|
sleep "$rootdelay"
|
||||||
fi
|
fi
|
||||||
if [ "$root" == "" ]; then
|
if [ "$root" == "" ]; then
|
||||||
if [ ! -f /etc/rc.d/init.d/setup-nutyx ]; then
|
if [ ! -f /etc/rc.d/init.d/milis-kur ]; then
|
||||||
find_media
|
find_media
|
||||||
if [ ! -L /dev/nutyx-cd ]; then
|
if [ ! -L /dev/cdrom ]; then
|
||||||
[ "$verbose" == "no" ] || echo "Media not found yet, trying again in 5 sec"
|
[ "$verbose" == "no" ] || echo "Media not found yet, trying again in 5 sec"
|
||||||
sleep 5
|
sleep 5
|
||||||
find_media
|
find_media
|
||||||
|
@ -270,13 +270,13 @@ if [ "$root" == "" ]; then
|
||||||
else
|
else
|
||||||
do_mount_in_ram /boot
|
do_mount_in_ram /boot
|
||||||
fi
|
fi
|
||||||
if [ ! -f /etc/rc.d/init.d/setup-nutyx ]; then
|
if [ ! -f /etc/rc.d/init.d/milis-kur ]; then
|
||||||
no_mount
|
no_mount
|
||||||
sh
|
sh
|
||||||
else
|
else
|
||||||
if [ "$verbose" == "yes" ]; then
|
if [ "$verbose" == "yes" ]; then
|
||||||
echo "/etc/rc.d/init.d/milis-kur exit ..."
|
echo "/etc/rc.d/init.d/milis-kur exit ..."
|
||||||
ls -lt /etc/rc.d/init.d/setup-nutyx
|
ls -lt /etc/rc.d/init.d/milis-kur
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
# TODO This doesn't works FIXME
|
# TODO This doesn't works FIXME
|
||||||
|
|
Loading…
Reference in New Issue