Bug 621836 - Corrupted ext3 filesystem with sparse journal not corrected by e2fsck
Corrupted ext3 filesystem with sparse journal not corrected by e2fsck
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: e2fsprogs (Show other bugs)
5.3
All Linux
urgent Severity urgent
: rc
: ---
Assigned To: Eric Sandeen
BaseOS QE - Apps
: ZStream
Depends On: 580671
Blocks:
  Show dependency treegraph
 
Reported: 2010-08-06 04:57 EDT by RHEL Product and Program Management
Modified: 2010-11-10 02:32 EST (History)
11 users (show)

See Also:
Fixed In Version: e2fsprogs-1.39-1.39-23.el5_5.1
Doc Type: Bug Fix
Doc Text:
Prior to this update, a corrupted journal on an ext3 file system may not have been properly repaired by the e2fsck utility. This was caused by the fact that the utility was unable to detect or repair the problem when the journal appeared to be a sparse file, which led to a journaling failure and file system shut down. With this update, the process_journal_block() function has been adjusted to mark sparse journal as invalid, and e2fsck utility now works as expected.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-10 02:32:31 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2010:0868 normal SHIPPED_LIVE e2fsprogs bug fix and enhancement update 2010-11-10 02:32:25 EST

  None (edit)
Description RHEL Product and Program Management 2010-08-06 04:57:39 EDT
This bug has been copied from bug #580671 and has been proposed
to be backported to 5.5 z-stream (EUS).
Comment 4 Eric Sandeen 2010-10-05 09:53:38 EDT
Fixed by:

http://git.kernel.org/?p=fs/ext2/e2fsprogs.git;a=commitdiff;h=5750e5f9246ead0bc2af7da0cb5bcdfc916cace6

From: Eric Sandeen <sandeen@redhat.com>
Date: Mon, 12 Apr 2010 22:36:33 +0000 (-0500)
Subject: e2fsck: mark sparse journal as invalid
X-Git-Url:
http://git.kernel.org/?p=fs%2Fext2%2Fe2fsprogs.git;a=commitdiff_plain;h=5750e5f9246ead0bc2af7da0cb5bcdfc916cace6

e2fsck: mark sparse journal as invalid

For a filesystem that fails with:

journal_bmap: journal block not found at offset 7334 on loop0
JBD: bad block at offset 7334

e2fsck won't actually fix this; it will mark the fs as clean,
so it will mount, but it does not fix that block, and when the
journal reaches this point again it will fail again.

The following simple change to process_journal_block() might be
a little drastic; it will clear & recreate the journal inode if
it's sparse - i.e. if it gets block 0.

I suppose we could be more complicated and try to replay the journal
up to the error, but I'm not sure it's worth it since we're fscking
it anyway.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Comment 5 Eric Sandeen 2010-10-05 12:15:07 EDT
Built in e2fsprogs-1.39-24
Comment 6 Eric Sandeen 2010-10-05 12:16:09 EDT
Make that: built in e2fsprogs-1.39-1.39-23.el5_5.1
Comment 9 Jaromir Hradilek 2010-11-09 13:35:21 EST
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Prior to this update, a corrupted journal on an ext3 file system may not have been properly repaired by the e2fsck utility. This was caused by the fact that the utility was unable to detect or repair the problem when the journal appeared to be a sparse file, which led to a journaling failure and file system shut down. With this update, the process_journal_block() function has been adjusted to mark sparse journal as invalid, and e2fsck utility now works as expected.
Comment 11 errata-xmlrpc 2010-11-10 02:32:31 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0868.html

Note You need to log in before you can comment on or make changes to this bug.