From: Kiyoshi Ueda <k-ueda@ct.jp.nec.com>
To: device-mapper development <dm-devel@redhat.com>
Cc: Alasdair Kergon <agk@redhat.com>, mbroz@redhat.com
Subject: Re: [PATCH 0/8] dm: request-based dm-multipath
Date: Fri, 30 Jan 2009 17:05:26 +0900 [thread overview]
Message-ID: <4982B4C6.8050904@ct.jp.nec.com> (raw)
In-Reply-To: <20090129104147.GB9870@pentland.suse.de>
Hi Hannes,
Thank you for the comments and patches.
See my comments below.
On 01/29/2009 07:41 PM +0900, Hannes Reinecke wrote:
> On Thu, Jan 29, 2009 at 04:18:59PM +0900, Kiyoshi Ueda wrote:
>> Hi Alasdair,
>>
>> On 01/29/2009 12:40 AM +0900, Alasdair G Kergon wrote:
>>> On Fri, Oct 03, 2008 at 11:08:25AM -0400, Kiyoshi Ueda wrote:
>>>> This patch-set is the updated version of request-based dm-multipath.
>>>> The changes from the previous version (*) are to follow up the change
>>>> of the interface to export lld's busy state (PATCH 5).
>>> I've fixed them up to compile again, but haven't thoroughly checked for
>>> side-effects.
>> I found some problems below in my patches and now considering
>> how to fix them:
>> o Unnecessary EIO is returned to application if it submits
>> a bio during table swapping.
> Yes, I've noticed that. Problem is this:
>
> --- linux-2.6.27.orig/drivers/md/dm.c
> +++ linux-2.6.27/drivers/md/dm.c
> @@ -1304,7 +1304,11 @@ static int dm_make_request(struct reques
> return 0;
> }
>
> - if (unlikely(!md->map)) {
> + /*
> + * Submitting to a stopped queue with no map is okay;
> + * might happen during reconfiguration.
> + */
> + if (unlikely(!md->map) && !blk_queue_stopped(q)) {
> bio_endio(bio, -EIO);
> return 0;
> }
>
> The make_request callback should never return EIO if there's any
> chance at all to get this request done.
Exactly this part has a race condition with table swapping.
Although you patch fixes the race condition, I think I need
more careful consideration here.
(e.g. Is it really OK to go bios through __make_request() with
old queue restrictions during table swapping?)
I'll work on this problem after my vacation.
>> o kernel panic occurs by frequent table swapping during heavy I/Os.
>>
> That's probably fixed by this patch:
>
> --- linux-2.6.27/drivers/md/dm.c.orig 2009-01-23 15:59:22.741461315 +0100
> +++ linux-2.6.27/drivers/md/dm.c 2009-01-26 09:03:02.787605723 +0100
> @@ -714,13 +714,14 @@ static void free_bio_clone(struct reques
> struct dm_rq_target_io *tio = clone->end_io_data;
> struct mapped_device *md = tio->md;
> struct bio *bio;
> - struct dm_clone_bio_info *info;
>
> while ((bio = clone->bio) != NULL) {
> clone->bio = bio->bi_next;
>
> - info = bio->bi_private;
> - free_bio_info(md, info);
> + if (bio->bi_private) {
> + struct dm_clone_bio_info *info = bio->bi_private;
> + free_bio_info(md, info);
> + }
>
> bio->bi_private = md->bs;
> bio_put(bio);
>
> The info field is not necessarily filled here, so we have to check for it
> explicitly.
>
> With these two patches request-based multipathing have survived all stress-tests
> so far. Except on mainframe (zfcp), but that's more a driver-related thing.
Hmm, it seems I'm hitting a different problem from the one you hit,
because I still see my problem even with your patch.
I need more investigation after my vacation.
Thanks,
Kiyoshi Ueda
next prev parent reply other threads:[~2009-01-30 8:05 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-03 15:08 [PATCH 0/8] dm: request-based dm-multipath Kiyoshi Ueda
2008-10-03 15:09 ` [PATCH 1/8] dm core: remove unused DM_WQ_FLUSH_ALL Kiyoshi Ueda
2008-10-03 15:09 ` Kiyoshi Ueda
2008-10-03 15:10 ` [PATCH 2/8] dm core: tidy local_init Kiyoshi Ueda
2008-10-03 15:17 ` [PATCH 3/8] dm core: add kmem_cache for request-based dm Kiyoshi Ueda
2008-10-03 15:18 ` [PATCH 4/8] dm core: add target interfaces " Kiyoshi Ueda
2008-10-03 15:18 ` Kiyoshi Ueda
2008-10-03 15:18 ` [PATCH 5/8] dm core: add core functions " Kiyoshi Ueda
2008-10-03 15:18 ` Kiyoshi Ueda
2008-10-03 15:19 ` [PATCH 6/8] dm core: enable " Kiyoshi Ueda
2008-10-03 15:19 ` Kiyoshi Ueda
2008-10-03 15:19 ` [PATCH 7/8] dm core: reject I/O violating new queue limits Kiyoshi Ueda
2008-10-03 15:19 ` Kiyoshi Ueda
2008-10-03 15:19 ` [PATCH 8/8] dm-mpath: convert to request-based Kiyoshi Ueda
2008-10-03 15:19 ` Kiyoshi Ueda
2009-01-28 15:40 ` [PATCH 0/8] dm: request-based dm-multipath Alasdair G Kergon
2009-01-29 7:18 ` Kiyoshi Ueda
2009-01-29 10:41 ` Hannes Reinecke
2009-01-29 14:32 ` Alasdair G Kergon
2009-01-30 8:05 ` Kiyoshi Ueda [this message]
2009-03-10 6:10 ` Kiyoshi Ueda
2009-03-10 7:17 ` Hannes Reinecke
2009-03-10 8:17 ` Kiyoshi Ueda
2009-03-11 12:28 ` Hannes Reinecke
2009-03-12 1:40 ` Kiyoshi Ueda
2009-03-12 8:58 ` Kiyoshi Ueda
2009-03-12 9:08 ` Hannes Reinecke
2009-03-13 1:03 ` Kiyoshi Ueda
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=4982B4C6.8050904@ct.jp.nec.com \
--to=k-ueda@ct.jp.nec.com \
--cc=agk@redhat.com \
--cc=dm-devel@redhat.com \
--cc=mbroz@redhat.com \
/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.