linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* ext4: oops on boot with root fs needing recovery
@ 2008-10-16 20:12 Jeremy Fitzhardinge
  2008-10-16 20:32 ` Theodore Tso
  0 siblings, 1 reply; 3+ messages in thread
From: Jeremy Fitzhardinge @ 2008-10-16 20:12 UTC (permalink / raw)
  To: Theodore Ts'o; +Cc: Eric Sandeen, linux-ext4, Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 589 bytes --]

I had a crash and rebooted.  The root filesystem needed journal 
recovery, but ext4 crashed.

My root fs is ext3 (no extents), but I've been mounting it as ext4 to 
see how it turns out.

The oops is new; booting an older kernel successfully recovered the 
journal (I've reverted the rootfs back to ext3 for now).

I'm using the Fedora rawhide packages.  The crashing kernel is 
2.6.27-13.fc10.x86_64.  2.6.27-1.fc10.x86_64 worked OK.

Oops image is attached.  Unfortunately the top of the oops got cut off, 
though I thought I saw some mention of the "extents" option flying past.

    J

[-- Attachment #2: ext4-rootfs-oops.jpg --]
[-- Type: image/jpeg, Size: 230998 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ext4: oops on boot with root fs needing recovery
  2008-10-16 20:12 ext4: oops on boot with root fs needing recovery Jeremy Fitzhardinge
@ 2008-10-16 20:32 ` Theodore Tso
  2008-10-16 20:42   ` Eric Sandeen
  0 siblings, 1 reply; 3+ messages in thread
From: Theodore Tso @ 2008-10-16 20:32 UTC (permalink / raw)
  To: Jeremy Fitzhardinge; +Cc: Eric Sandeen, linux-ext4, Linux Kernel Mailing List

On Thu, Oct 16, 2008 at 01:12:03PM -0700, Jeremy Fitzhardinge wrote:
> I had a crash and rebooted.  The root filesystem needed journal  
> recovery, but ext4 crashed.
>
> My root fs is ext3 (no extents), but I've been mounting it as ext4 to  
> see how it turns out.

Yeah, known bug.  I'll push a patch to Linus to fix this.

      	    	       	      	       	     - Ted

ext4: Do mballoc init before doing filesystem recovery

From: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>

During filesystem recovery we may be doing a truncate
which expects some of the mballoc data structures to
be initialized. So do ext4_mb_init before recovery.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>

diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index 0e661c5..6ca2146 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -2441,6 +2441,21 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)
 			"available.\n");
 	}
 
+	if (test_opt(sb, DATA_FLAGS) == EXT4_MOUNT_JOURNAL_DATA) {
+		printk(KERN_WARNING "EXT4-fs: Ignoring delalloc option - "
+				"requested data journaling mode\n");
+		clear_opt(sbi->s_mount_opt, DELALLOC);
+	} else if (test_opt(sb, DELALLOC))
+		printk(KERN_INFO "EXT4-fs: delayed allocation enabled\n");
+
+	ext4_ext_init(sb);
+	err = ext4_mb_init(sb, needs_recovery);
+	if (err) {
+		printk(KERN_ERR "EXT4-fs: failed to initalize mballoc (%d)\n",
+		       err);
+		goto failed_mount4;
+	}
+
 	/*
 	 * akpm: core read_super() calls in here with the superblock locked.
 	 * That deadlocks, because orphan cleanup needs to lock the superblock
@@ -2460,21 +2475,6 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)
 	       test_opt(sb, DATA_FLAGS) == EXT4_MOUNT_ORDERED_DATA ? "ordered":
 	       "writeback");
 
-	if (test_opt(sb, DATA_FLAGS) == EXT4_MOUNT_JOURNAL_DATA) {
-		printk(KERN_WARNING "EXT4-fs: Ignoring delalloc option - "
-				"requested data journaling mode\n");
-		clear_opt(sbi->s_mount_opt, DELALLOC);
-	} else if (test_opt(sb, DELALLOC))
-		printk(KERN_INFO "EXT4-fs: delayed allocation enabled\n");
-
-	ext4_ext_init(sb);
-	err = ext4_mb_init(sb, needs_recovery);
-	if (err) {
-		printk(KERN_ERR "EXT4-fs: failed to initalize mballoc (%d)\n",
-		       err);
-		goto failed_mount4;
-	}

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: ext4: oops on boot with root fs needing recovery
  2008-10-16 20:32 ` Theodore Tso
@ 2008-10-16 20:42   ` Eric Sandeen
  0 siblings, 0 replies; 3+ messages in thread
From: Eric Sandeen @ 2008-10-16 20:42 UTC (permalink / raw)
  To: Theodore Tso, Jeremy Fitzhardinge, Eric Sandeen, linux-ext4,
	Linux Kernel Mailing List

Theodore Tso wrote:
> On Thu, Oct 16, 2008 at 01:12:03PM -0700, Jeremy Fitzhardinge wrote:
>> I had a crash and rebooted.  The root filesystem needed journal  
>> recovery, but ext4 crashed.
>>
>> My root fs is ext3 (no extents), but I've been mounting it as ext4 to  
>> see how it turns out.
> 
> Yeah, known bug.  I'll push a patch to Linus to fix this.
> 
>       	    	       	      	       	     - Ted
>

Jeremy, I see you're using an f10 kernel; it'll be in the next kernel
build there, as well.

-Eric

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-10-16 20:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-16 20:12 ext4: oops on boot with root fs needing recovery Jeremy Fitzhardinge
2008-10-16 20:32 ` Theodore Tso
2008-10-16 20:42   ` Eric Sandeen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).