Whamcloud - gitweb
e2fsck: Add the ability to force a problem to not be fixed
authorTheodore Ts'o <tytso@mit.edu>
Mon, 6 Dec 2010 15:10:33 +0000 (10:10 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 6 Dec 2010 15:10:33 +0000 (10:10 -0500)
commit75990388365c5688dbade9c33a3394e40f757526
treee6de396e647ae73ed0d49941e61023ffd160bad9
parent0e2afdbaccbd56d58c291763bac5902032bf5f53
e2fsck: Add the ability to force a problem to not be fixed

The boolean options "force_no" in the problems stanza of e2fsck.conf
allows a particular problem code be treated as if the user will answer
"no" to the question of whether a particular problem should be fixed
--- even if e2fsck is run with the -y option.

As an example use case, suppose a distribution had widely deployed a
version of the kernel where under some circumstances, the EOFBLOCKS_FL
flag would be left set even though it should not be left set, and a
customer had a workload which exercised the fencepost error all the
time, resulting in many large number of inodes that had EOFBLOCKS_FL
set erroneously.  Enough, in fact, the e2fsck runs were taking too
long.  (There was such a bug in the kernel, which was fixed by commit
58590b06d in 2.6.36).

Leaving EOFBLOCKS_FL set when it should not be isn't a huge deal, and
is certainly than having high availability timeout alerts going off
left and right.  So in this case, the best fix might be to put the
following in /etc/e2fsck.conf:

[problems]
0x010060 = { # PR_1_EOFBLOCKS_FL_SET
 force_no = true
 no_ok = true
 no_nomsg = true
}

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
e2fsck/e2fsck.conf.5.in
e2fsck/problem.c
e2fsck/problemP.h