]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ocfs2: add errors=continue
authorGoldwyn Rodrigues <rgoldwyn@suse.de>
Tue, 7 Apr 2015 23:43:57 +0000 (09:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 7 Apr 2015 23:43:57 +0000 (09:43 +1000)
commitb9201fecb55e09044ec676f2e01cffe23f6fc006
tree8fa77db74fa39af4179fdc85576e2c8016ab1b7d
parent9c7bc2a277941bc6238215c6489ecef4c5c499e6
ocfs2: add errors=continue

OCFS2 is often used in high-availaibility systems.  However, ocfs2
converts the filesystem to read-only at the drop of the hat.  This may not
be necessary, since turning the filesystem read-only would affect other
running processes as well, decreasing availability.

This attempt is to add errors=continue, which would return the EIO to the
calling process and terminate furhter processing so that the filesystem is
not corrupted further.  However, the filesystem is not converted to
read-only.

As a future plan, I intend to create a small utility or extend fsck.ocfs2
to fix small errors such as in the inode.  The input to the utility such
as the inode can come from the kernel logs so we don't have to schedule a
downtime for fixing small-enough errors.

The patch changes the ocfs2_error to return an error.  The error returned
depends on the mount option set.  If none is set, the default is to turn
the filesystem read-only.

Perhaps errors=continue is not the best option name.  Historically it is
used for making an attempt to progress in the current process itself.
Should we call it errors=eio?  or errors=killproc?  Suggestions/Comments
welcome.

Sources are available at:
https://github.com/goldwynr/linux/tree/error-cont

Signed-off-by: Goldwyn Rodrigues <rgoldwyn@suse.com>
Cc: Mark Fasheh <mfasheh@suse.com>
Cc: Joel Becker <jlbec@evilplan.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
fs/ocfs2/ocfs2.h
fs/ocfs2/super.c
fs/ocfs2/super.h