Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#559301: How can I fsck a filesytem after the journal has been destroyed?

117 views
Skip to first unread message

John Hughes

unread,
Jun 30, 2010, 6:20:03 AM6/30/10
to
Actualy this is even worse than I thought.

If an external journal gets destroyed there appears to be no way to fsck
the filesystem.

I have an ext3 filesystem on /dev/group-a/ums which has a journal on
/dev/flash/ums-journal. Some terrible accident causes the destruction
of the journal. Now how do I fsck the filesystem?

lvremove /dev/flash/ums-journal
Do you really want to remove active logical volume ums-journal? [y/n]: y
Logical volume "ums-journal" successfully removed
root@acadia:~/ums-benchmark# fsck /dev/group-a/ums
fsck from util-linux-ng 2.16.2
e2fsck 1.41.12 (17-May-2010)
Can't find external journal
root@acadia:~/ums-benchmark# tune2fs -f -O ^has_journal /dev/group-a/ums
tune2fs 1.41.12 (17-May-2010)
root@acadia:~/ums-benchmark# fsck.ext3 /dev/group-a/ums
e2fsck 1.41.12 (17-May-2010)
Can't find external journal

What with this and bug 587531 external journals look pretty dodgy.


--
To UNSUBSCRIBE, email to debian-bugs-...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org

ty...@mit.edu

unread,
Jun 30, 2010, 9:30:02 AM6/30/10
to
On Wed, Jun 30, 2010 at 12:17:09PM +0200, John Hughes wrote:
> Actualy this is even worse than I thought.
>
> If an external journal gets destroyed there appears to be no way to
> fsck the filesystem.
>
> I have an ext3 filesystem on /dev/group-a/ums which has a journal on
> /dev/flash/ums-journal. Some terrible accident causes the
> destruction of the journal. Now how do I fsck the filesystem?

Here's a workaround for now:

debugfs -w /dev/group-a/ums
debugfs: ssv journal_uuid null
debugfs: ssv journal_inum 0
debugfs: feature ^needs_recovery
debugfs: feature ^has_journal
debugfs: quit

... and then run e2fsck -f on the file system.

In the long run e2fsck will need an extended feature that explicitly
requests it to abandon an external journal. I don't want to make this
too easy to do, since if a disk goes temporarily off-line, we don't
want "e2fsck -y" to just blindly nuke the external journal.

- Ted

0 new messages