I modified /etc/init/mountall.conf as follows:
$ diff -u mountall.conf.old mountall.conf --- mountall.conf.old 2009-09-25 05:40:33.331304981 -0400 +++ mountall.conf 2009-09-25 05:39:48.551305237 -0400 @@ -22,6 +22,10 @@ console output
script + mount -t tmpfs none /tmp + exec > /tmp/mountall.log 2>&1 + set -x + cat /proc/mounts . /etc/default/rcS [ -f /forcefsck ] && force_fsck="--force-fsck" [ "$FSCKFIX" = "yes" ] && fsck_fix="--fsck-fix"
When the /forcefsck file is not present, I get the following logged to /tmp/mountall.log:
+ cat /proc/mounts rootfs / rootfs rw 0 0 none /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0 none /proc proc rw,nosuid,nodev,noexec,relatime 0 0 udev /dev tmpfs rw,relatime,mode=755 0 0 /dev/mapper/grok-root / ext4 ro,relatime,barrier=1,data=ordered 0 0 none /sys/kernel/security securityfs rw,relatime 0 0 none /tmp tmpfs rw,relatime 0 0 + . /etc/default/rcS + TMPTIME=0 + SULOGIN=no + DELAYLOGIN=no + UTC=yes + VERBOSE=no + FSCKFIX=no + RAMRUN=yes + RAMLOCK=yes + [ -f /forcefsck ] + [ no = yes ] + [ -n 0 ] + tmptime=--tmptime=0 + exec mountall --daemon --tmptime=0 fsck from util-linux-ng 2.16 fsck from util-linux-ng 2.16 root: clean, 436712/7192576 files, 5188293/28753920 blocks boot: clean, 167/62248 files, 31424/248976 blocks
When /forcefsck is present, I get the following logged to /tmp/mountall.log:
+ cat /proc/mounts rootfs / rootfs rw 0 0 none /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0 none /proc proc rw,nosuid,nodev,noexec,relatime 0 0 udev /dev tmpfs rw,relatime,mode=755 0 0 /dev/mapper/grok-root / ext4 ro,relatime,barrier=1,data=ordered 0 0 none /sys/kernel/security securityfs rw,relatime 0 0 none /tmp tmpfs rw,relatime 0 0 + . /etc/default/rcS + TMPTIME=0 + SULOGIN=no + DELAYLOGIN=no + UTC=yes + VERBOSE=no + FSCKFIX=no + RAMRUN=yes + RAMLOCK=yes + [ -f /forcefsck ] + force_fsck=--force-fsck + [ no = yes ] + [ -n 0 ] + tmptime=--tmptime=0 + exec mountall --daemon --force-fsck --tmptime=0 fsck from util-linux-ng 2.16 fsck from util-linux-ng 2.16 boot: 167/62248 files (0.0% non-contiguous), 31424/248976 blocks root: 436712/7192576 files (0.3% non-contiguous), 5188229/28753920 blocks
So the --force-fsck argument is being passed to mountall. Mountall appears to be running fsck in both cases, but there must be different command-line arguments. However, mountall isn't running fsck.ext4 with the -f option.
I modified /etc/init/ mountall. conf as follows:
$ diff -u mountall.conf.old mountall.conf
--- mountall.conf.old 2009-09-25 05:40:33.331304981 -0400
+++ mountall.conf 2009-09-25 05:39:48.551305237 -0400
@@ -22,6 +22,10 @@
console output
script "--force- fsck" "--fsck- fix"
+ mount -t tmpfs none /tmp
+ exec > /tmp/mountall.log 2>&1
+ set -x
+ cat /proc/mounts
. /etc/default/rcS
[ -f /forcefsck ] && force_fsck=
[ "$FSCKFIX" = "yes" ] && fsck_fix=
When the /forcefsck file is not present, I get the following logged to /tmp/mountall.log:
+ cat /proc/mounts nodev,noexec, relatime 0 0 nodev,noexec, relatime 0 0 mode=755 0 0 grok-root / ext4 ro,relatime, barrier= 1,data= ordered 0 0 security securityfs rw,relatime 0 0
rootfs / rootfs rw 0 0
none /sys sysfs rw,nosuid,
none /proc proc rw,nosuid,
udev /dev tmpfs rw,relatime,
/dev/mapper/
none /sys/kernel/
none /tmp tmpfs rw,relatime 0 0
+ . /etc/default/rcS
+ TMPTIME=0
+ SULOGIN=no
+ DELAYLOGIN=no
+ UTC=yes
+ VERBOSE=no
+ FSCKFIX=no
+ RAMRUN=yes
+ RAMLOCK=yes
+ [ -f /forcefsck ]
+ [ no = yes ]
+ [ -n 0 ]
+ tmptime=--tmptime=0
+ exec mountall --daemon --tmptime=0
fsck from util-linux-ng 2.16
fsck from util-linux-ng 2.16
root: clean, 436712/7192576 files, 5188293/28753920 blocks
boot: clean, 167/62248 files, 31424/248976 blocks
When /forcefsck is present, I get the following logged to /tmp/mountall.log:
+ cat /proc/mounts nodev,noexec, relatime 0 0 nodev,noexec, relatime 0 0 mode=755 0 0 grok-root / ext4 ro,relatime, barrier= 1,data= ordered 0 0 security securityfs rw,relatime 0 0 --force- fsck
rootfs / rootfs rw 0 0
none /sys sysfs rw,nosuid,
none /proc proc rw,nosuid,
udev /dev tmpfs rw,relatime,
/dev/mapper/
none /sys/kernel/
none /tmp tmpfs rw,relatime 0 0
+ . /etc/default/rcS
+ TMPTIME=0
+ SULOGIN=no
+ DELAYLOGIN=no
+ UTC=yes
+ VERBOSE=no
+ FSCKFIX=no
+ RAMRUN=yes
+ RAMLOCK=yes
+ [ -f /forcefsck ]
+ force_fsck=
+ [ no = yes ]
+ [ -n 0 ]
+ tmptime=--tmptime=0
+ exec mountall --daemon --force-fsck --tmptime=0
fsck from util-linux-ng 2.16
fsck from util-linux-ng 2.16
boot: 167/62248 files (0.0% non-contiguous), 31424/248976 blocks
root: 436712/7192576 files (0.3% non-contiguous), 5188229/28753920 blocks
So the --force-fsck argument is being passed to mountall. Mountall appears to be running fsck in both cases, but there must be different command-line arguments. However, mountall isn't running fsck.ext4 with the -f option.