Bug 621836 - Corrupted ext3 filesystem with sparse journal not corrected by e2fsck
Summary: Corrupted ext3 filesystem with sparse journal not corrected by e2fsck
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: e2fsprogs
Version: 5.3
Hardware: All
OS: Linux
urgent
urgent
Target Milestone: rc
: ---
Assignee: Eric Sandeen
QA Contact: BaseOS QE - Apps
URL:
Whiteboard:
Depends On: 580671
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-08-06 08:57 UTC by RHEL Program Management
Modified: 2010-11-10 07:32 UTC (History)
11 users (show)

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.
Clone Of:
Environment:
Last Closed: 2010-11-10 07:32:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2010:0868 0 normal SHIPPED_LIVE e2fsprogs bug fix and enhancement update 2010-11-10 07:32:25 UTC

Description RHEL Program Management 2010-08-06 08:57:39 UTC
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 13:53:38 UTC
Fixed by:

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

From: Eric Sandeen <sandeen>
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>
Signed-off-by: Theodore Ts'o <tytso>

Comment 5 Eric Sandeen 2010-10-05 16:15:07 UTC
Built in e2fsprogs-1.39-24

Comment 6 Eric Sandeen 2010-10-05 16:16:09 UTC
Make that: built in e2fsprogs-1.39-1.39-23.el5_5.1

Comment 9 Jaromir Hradilek 2010-11-09 18:35:21 UTC
    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 07:32:31 UTC
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.