All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sandeen <sandeen@redhat.com>
To: "Theodore Ts'o" <tytso@mit.edu>
Cc: David Jeffery <djeffery@redhat.com>, linux-ext4@vger.kernel.org
Subject: Re: [PATCH] e2fsck: detect invalid extents at the end of an extent-block
Date: Thu, 06 Jun 2013 22:40:37 -0500	[thread overview]
Message-ID: <51B15635.1000406@redhat.com> (raw)
In-Reply-To: <20130607033508.GA7555@thunk.org>

On 6/6/13 10:35 PM, Theodore Ts'o wrote:
> On Tue, Jun 04, 2013 at 02:53:51PM -0500, Eric Sandeen wrote:
>>
>> Here's an image which demonstrates this, current e2fsck does not detect
>> the error.
> 
> Thanks.  For future reference, here's how you can use debugfs to
> generate a much smaller image which demonstrates the problem, suitable
> for use in a regression test.

Ah.  Well, I did use debugfs to make it, but not quite so compactly.  :)

Thanks,
-Eric

> 					- Ted
> 
> #!/bin/sh
> dd if=/dev/zero of=image bs=1k count=256
> mke2fs -Ft ext4 image
> debugfs -w image << EOF
> write /dev/null testfile
> extent_open testfile
>   insert_node 0 15 100
>   insert_node --after 15 15 115
>   insert_node --after 30 15 130
>   insert_node --after 45 15 145
>   split
>   down
>   split
>   root
>   down
>   next
>   replace_node 15 30 200
>   extent_close
> set_inode_field testfile i_size 61400
> set_inode_field testfile i_blocks 154
> setb 100 15
> setb 130 30
> setb 200 30
> set_bg 0 free_blocks_count 156
> set_bg 0 bg_checksum calc
> set_super_value free_blocks_count 156
> EOF
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


  reply	other threads:[~2013-06-07  3:40 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-03 19:08 [PATCH] e2fsck: detect invalid extents at the end of an extent-block David Jeffery
2013-06-04 19:53 ` Eric Sandeen
2013-06-07  3:35   ` Theodore Ts'o
2013-06-07  3:40     ` Eric Sandeen [this message]
2013-06-04 21:54 ` Eric Sandeen
2013-06-07  3:39   ` Theodore Ts'o
2013-07-16 14:24     ` Dmitry Monakhov
2013-07-16 15:17       ` Eric Sandeen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51B15635.1000406@redhat.com \
    --to=sandeen@redhat.com \
    --cc=djeffery@redhat.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=tytso@mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.