4

If I have the 6th column in fstab (the pass column) set to 0, does that mean checks will never be forced at boot regardless of anything like File System State, Mount Count, and Check Interval on the file system itself (see dumpe2fs)?

The fstab manpage does state:

If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked.

But maybe there is an exception?

Kyle Brandt
  • 82,107
  • 71
  • 302
  • 444
  • P.S. Rather not get into the whole 'Should you really be disabling fsck thing' , but I guess if you must ... :-) – Kyle Brandt Mar 09 '10 at 16:56

2 Answers2

2

You're reading the manpage right: If pass is zero the filesystem won't be fed to fsck for a check on boot (which can cause a bunch problems if you subsequently try to mount a dirty filesystem).

There may be an exception on Linux systems: the EXT filesystems have those annoying "Check every N mounts" / "Check every N days" triggers (because apparently you can't trust the FS even if it's marked clean), and I believe they happen as part of the mount rather than as a startup check, so they might circumvent the pass logic.

voretaq7
  • 79,345
  • 17
  • 128
  • 213
  • Guess I may have to Try It And See (TIAS) as far as the mount count goes. I think I can set that with `tune2fs`. – Kyle Brandt Mar 09 '10 at 17:01
  • yeah, I usually crank the intervals way up. Never exactly got the warm fuzzies of confidence from the fact that there has to be a check interval, but EXT & I have a long history of data loss and mutual loathing :-) – voretaq7 Mar 09 '10 at 17:08
  • 2
    Boot time mount doesn't seem to be affected by the tune2fs -c value (RHEL5). With column 6 set to 0 it just whistles on by. – gm3dmo Mar 09 '10 at 17:19
  • Dacey: Why don't you put these comments in an answer to so I can upvote and accept it :-) – Kyle Brandt Mar 10 '10 at 12:44
2

On CentOS, if the file /forcefsck exists on the filesystem, I believe this will override the fstab setting.

Warner
  • 23,440
  • 2
  • 57
  • 69
  • Interesting tidbit (But... if the FS is hosed & needs to be checked how would I know if `/forcefsck` existed? (I'm Just Sayin'. Somewhere there's a chicken looking for its egg, or vice-versa :-) ) – voretaq7 Mar 09 '10 at 17:06
  • Right with you. I've always believed to be the fstab setting to take priority during mounting but I can't say for fact. It's a good question and you have a good answer. – Warner Mar 09 '10 at 17:08
  • 1
    I think that /forcefsck has to exist on the root filesystem "/" and it causes a check on all filesystems regardless of their column 6 setting (tested on RHEL5). This behaviour is all controlled by /etc/rc.d/rc.sysinit. – gm3dmo Mar 09 '10 at 17:23