diff --git a/etc/rc.d/init.d/checkfs b/etc/rc.d/init.d/checkfs index cb7583e..883cd88 100755 --- a/etc/rc.d/init.d/checkfs +++ b/etc/rc.d/init.d/checkfs @@ -13,28 +13,29 @@ if [ -f /fastboot ]; then exit 0 fi -echo -n "Mounting root file system in read-only mode: " -mount -n -o remount,ro / -retval=$? +echo -n "Checking file systems: " +$PLYMOUTH message --text=$"Checking file systems..." -if [ $retval != 0 ]; then - $FAILURE - echo - echo "Cannot check root file system because it could not" - echo "be mounted in read-only mode." - echo - echo -n "When you press enter, this system will be halted." - $NORMAL - echo - echo "Press enter to continue..." - read ans - echo "gonna run: $rc_base/init.d/halt" - $rc_base/init.d/halt +if [ ! -e /run/initramfs/root-fsck ]; then + echo -n "Mounting root file system in read-only mode: " + mount -n -o remount,ro / + retval=$? + + if [ $retval != 0 ]; then + $FAILURE + echo "Cannot check root file system because it could not" + echo "be mounted in read-only mode." + echo + $NORMAL + $PLYMOUTH message --text=$"Checking file systems...operational error!" + echo_warning + echo + else + echo_success + echo + fi fi -echo_success -echo - if [ -f /forcefsck ]; then echo "/forcefsck exists, forcing file system check" options="-f" @@ -42,9 +43,6 @@ else options="" fi -echo -n "Checking file systems: " -$PLYMOUTH message --text=$"Checking file systems..." - # note: -a option used to be -p; but this fails e.g. on fsck.minix fsck $options -a -A -C -T retval=$?