|
|
|
@ -726,7 +726,7 @@ fi
|
|
|
|
|
if [ "$0" = '/linuxrc' ] || [ "$0" = 'linuxrc' ]
|
|
|
|
|
then
|
|
|
|
|
[ ! -e ${CHROOT}/dev/console ] && mknod ${CHROOT}/dev/console c 5 1
|
|
|
|
|
echo -ne "${GOOD}>>${NORMAL}${BOLD} Booting"
|
|
|
|
|
echo -ne "${GOOD}>>${NORMAL}${BOLD} Booting${NORMAL}"
|
|
|
|
|
|
|
|
|
|
cd ${CHROOT}
|
|
|
|
|
mkdir ${CHROOT}/proc ${CHROOT}/sys 2>/dev/null
|
|
|
|
@ -735,7 +735,7 @@ then
|
|
|
|
|
then
|
|
|
|
|
sleep 10
|
|
|
|
|
fi
|
|
|
|
|
echo -n '.'
|
|
|
|
|
echo -ne "${BOLD}.${NORMAL}"
|
|
|
|
|
|
|
|
|
|
if /tmp/.initrd/bin/[ "${USE_DEVFS_NORMAL}" -eq '1' -a "${CDROOT}" -eq '0' ]
|
|
|
|
|
then
|
|
|
|
@ -762,13 +762,13 @@ then
|
|
|
|
|
umount /sys 2>/dev/null
|
|
|
|
|
umount /tmp/.initrd/sys 2>/dev/null
|
|
|
|
|
fi
|
|
|
|
|
echo -n '.'
|
|
|
|
|
echo -ne "${BOLD}.${NORMAL}"
|
|
|
|
|
|
|
|
|
|
# /usr/src/linux/Documentation/initrd.txt:
|
|
|
|
|
# exec chroot . /sbin/init </dev/console >/dev/console 2>&1
|
|
|
|
|
|
|
|
|
|
echo -e "${BOLD}.${NORMAL}"
|
|
|
|
|
exec <dev/console >dev/console 2>&1
|
|
|
|
|
echo '.'
|
|
|
|
|
exec chroot . /bin/sh <<- EOF
|
|
|
|
|
umount /tmp/.initrd || echo "*: Failed to unmount the initrd!"
|
|
|
|
|
/sbin/blockdev --flushbufs /dev/ram0 >/dev/null 2>&1
|
|
|
|
@ -778,14 +778,14 @@ elif [ "$0" = '/init' ]
|
|
|
|
|
then
|
|
|
|
|
[ ! -e ${CHROOT}/dev/console ] && mknod ${CHROOT}/dev/console c 5 1
|
|
|
|
|
[ ! -e ${CHROOT}/dev/tty1 ] && mknod ${CHROOT}/dev/tty1 c 4 1
|
|
|
|
|
echo -ne "${GOOD}>>${NORMAL}${BOLD} Booting (initramfs)"
|
|
|
|
|
echo -ne "${GOOD}>>${NORMAL}${BOLD} Booting (initramfs)${NORMAL}"
|
|
|
|
|
|
|
|
|
|
cd ${CHROOT}
|
|
|
|
|
mkdir ${CHROOT}/proc ${CHROOT}/sys 2>/dev/null
|
|
|
|
|
echo -n '.'
|
|
|
|
|
echo -ne "${BOLD}.${NORMAL}"
|
|
|
|
|
umount /sys || echo '*: Failed to unmount the initrd /sys!'
|
|
|
|
|
umount /proc || echo '*: Failed to unmount the initrd /proc!'
|
|
|
|
|
echo -n '.'
|
|
|
|
|
echo -e "${BOLD}.${NORMAL}"
|
|
|
|
|
|
|
|
|
|
exec switch_root -c "/dev/console" "${CHROOT}" ${REAL_INIT:-/sbin/init} ${INIT_OPTS}
|
|
|
|
|
fi
|
|
|
|
|