On Wed, Apr 13, 2016 at 07:52:02PM +1000, Dmitry Smirnov wrote:
> 
> As you can see there is a deadlock: I can't remove reference to non existent 
> external journal before running _fsck_ which refuses to work when journal is 
> not available. Catch-22?

So the workaround is this:

debugfs -w -R "features ^needs_recovery,^has_journal" /dev/sdXX
e2fsck -f /dev/sdXX
tune2fs -O has_journal /dev/sdXX

The reason why we haven't really dealt with this case is because it's
fundamentally a UI issue, and there aren't good answers about the best
way to deal with this.  It would be really easy for e2fsck to just do
this, but if the external journal is only temporarily unavailable, we
**really** don't want to be encouraging system administrators to do
this, because trying to fix the file system without the feature can
lead to data loss, which could have been avoided if the journal device
can be brought back (or was just in a non-standard /dev/sdXX name when
the user fired off the e2fsck -fy command.

I should just make a decision, probably with a large message with
warnings in upper case and a question which does NOT honor the e2fsck
-y option.

Cheers,

                                                - Ted

Reply via email to