From: Kerin Millar <kerframil@gmail.com>
To: NeilBrown <neilb@suse.de>
Cc: linux-raid@vger.kernel.org
Subject: Re: raid10 make_request failure during iozone benchmark upon btrfs
Date: Sat, 07 Jul 2012 18:29:02 +0100 [thread overview]
Message-ID: <4FF871DE.4060805@gmail.com> (raw)
In-Reply-To: <20120703124727.6e2232d1@notabene.brown>
On 03/07/2012 03:47, NeilBrown wrote:
[snip]
> Thanks. Looks like it is a btrfs bug - so a big "hello" to linux-btrfs :-)
>
> The symptom is that iozone on btrfs on md/raid10 can result in
>
> [ 919.893454] md/raid10:md0: make_request bug: can't convert block across chunks or bigger than 256k 6653500160 256
> [ 919.893465] btrfs: bdev /dev/mapper/vg0-test errs: wr 1, rd 0, flush 0, corrupt 0, gen 0
>
>
> i.e. RAID10 has a 256K chunk size, but is getting 256K requests which overlap
> two chunks - the last half of one chunk and the first half of the next.
> That isn't allowed and raid10_mergeable_bvec, called by bio_add_page, should
> prevent it.
>
> However btrfs_map_bio() sets ->bi_sector to a new value without verifying
> that the resulting bio is still acceptable - which it isn't.
>
> The core problem is that you cannot build a bio for one location, then use it
> freely at another location.
> md/raid1 handles this by checking each addition to a bio against all the
> possible location that it might read/write it. Maybe btrfs could do the
> same.
> Alternately we could work with Kent Overstreet (of bcache fame) to remove the
> restriction that the fs must make the bio compatible with the device -
> instead requiring the device to split bios when needed, and making it easy to
> do that (currently it is not easy).
> And there are probably other alternative.
>
Thanks very much for identifying the bug. I'm glad to find that the raid
subsystem is not at fault. I'll give btrfs a spin at some point in the
future and see whether anything has changed by then.
Cheers,
--Kerin
prev parent reply other threads:[~2012-07-07 17:29 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-02 2:34 raid10 make_request failure during iozone benchmark upon btrfs Kerin Millar
2012-07-02 2:52 ` NeilBrown
2012-07-02 2:58 ` Kerin Millar
2012-07-03 1:39 ` NeilBrown
2012-07-03 2:13 ` Kerin Millar
2012-07-03 2:47 ` NeilBrown
2012-07-03 15:08 ` Chris Mason
2012-07-07 17:29 ` Kerin Millar [this message]
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=4FF871DE.4060805@gmail.com \
--to=kerframil@gmail.com \
--cc=linux-raid@vger.kernel.org \
--cc=neilb@suse.de \
/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 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).