Linux Device Mapper development
 help / color / mirror / Atom feed
From: Martin Wilck <mwilck@suse.com>
To: Benjamin Marzinski <bmarzins@redhat.com>, Hannes Reinecke <hare@suse.de>
Cc: dm-devel@redhat.com, Xose Vazquez Perez <xose.vazquez@gmail.com>
Subject: Re: [PATCH v3 11/11] libmultipath: don't [un]set queue_if_no_path after domap
Date: Thu, 22 Jun 2017 22:44:53 +0200	[thread overview]
Message-ID: <1498164293.4743.3.camel@suse.com> (raw)
In-Reply-To: <20170622192129.GP2940@octiron.msp.redhat.com>

On Thu, 2017-06-22 at 14:21 -0500, Benjamin Marzinski wrote:
> On Thu, Jun 22, 2017 at 08:23:44AM +0200, Hannes Reinecke wrote:
> > On 06/21/2017 05:06 PM, Martin Wilck wrote:
> > > We set the queue_if_no_path feature in assemble_map() already,
> > > no need to set it here again.
> > > 
> > > Signed-off-by: Martin Wilck <mwilck@suse.com>
> > > ---
> > >  libmultipath/configure.c | 15 ---------------
> > >  1 file changed, 15 deletions(-)
> > > 
> > > 
> > 
> > Watch out.
> > 'queue_if_no_path' is set _temporarily_ while 'no_path_retry' is
> > active,
> > and removed afterwards.
> > So there might be valid reasons why it's set here.
> > Have you checked?
> 
> IIRC, we used to always set queue_if_no_path before reloading the
> map,

Why? I've searched for comments explaining that but found nothing.
Anyway, we've ceased to do so at least since 7331cf5 "Correctly update
feature strings", merged in May 2011.

> and then call setup_multipath() afterwards, which would call
> set_no_path_retry() to set it to the actual correct value. 

setup_multipath() is called too, a bit later in the code flow, from
configure() after coalesce_paths() and coalesce_maps(). So we're
currently setting queue_if_no_path 3 times when creating maps: in
domap(), after domap(), and in setup_multipath->set_no_path_retry().
With my patch, we do it only twice :-)

The call to dm_queue_if_no_path directly after domap(), which my patch
removes, is ancient, it came with 0e6e3113 "[multipath] Extension of
the "no_path_retry" scope to the multipath" in 2005.

> If we are
> correctly setting the feature line when we reload the map, that's a
> better solution. Obviously, we can't strip set_no_path_retry() out of
> __setup_multipath() since we rely on that to deal with deal with
> going
> into recovery mode. However, without some more thought and code
> reading,
> I'm not sure if we do still need the calls to dm_queue_if_no_path()
> there for some other reason anymore.  At any rate, they won't hurt
> anything, except for causing a redundant call to device-mapper.
> 
> Also, if we're yanking these dm_queue_if_no_path() calls from
> coalesce_paths, I don't see why we need them in reload_map(), where
> they
> also seem redundant if we just correctly set the features argument
> when
> we reloaded the table.
> 
> ACK, but I wouldn't mind seeing the calls pulled from reload_map as
> well.

Agreed, but I propose to do that in a separate patch. No need to repost
the whole series for that.

Martin

-- 
Dr. Martin Wilck <mwilck@suse.com>, Tel. +49 (0)911 74053 2107
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel

  reply	other threads:[~2017-06-22 20:44 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-21 15:06 [PATCH v3 00/11] multipath-tools: no_path_retry/queue_if_no_path/hwhandler logic Martin Wilck
2017-06-21 15:06 ` [PATCH v3 01/11] libmultipath: load_config: skip setting unnecessary defaults Martin Wilck
2017-06-22  6:01   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 02/11] libmultipath: add/remove_feature: use const char* for feature Martin Wilck
2017-06-21 15:06 ` [PATCH v3 03/11] libmultipath: clarify option conflicts for "features" Martin Wilck
2017-06-22  6:02   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 04/11] libmultipath: merge_hwe: fix queue_if_no_path logic Martin Wilck
2017-06-22  6:04   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 05/11] libmultipath: assemble_map: " Martin Wilck
2017-06-22  6:05   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 06/11] multipath.conf.5: document no_path_retry vs. queue_if_no_path Martin Wilck
2017-06-22  6:05   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 07/11] multipath.conf.5: Remove ??? and other minor fixes Martin Wilck
2017-06-22  6:06   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 08/11] libmultipath: add deprecated warning for some features settings Martin Wilck
2017-06-22  6:06   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 09/11] libmultipath: retain_attached_hw_handler obsolete with 4.3+ Martin Wilck
2017-06-22  6:07   ` Hannes Reinecke
2017-06-21 15:06 ` [PATCH v3 10/11] libmultipath: don't try to set hwhandler if it is retained Martin Wilck
2017-06-22  6:21   ` Hannes Reinecke
2017-06-22  9:58     ` Martin Wilck
2017-06-21 15:06 ` [PATCH v3 11/11] libmultipath: don't [un]set queue_if_no_path after domap Martin Wilck
2017-06-22  6:23   ` Hannes Reinecke
2017-06-22  9:34     ` Martin Wilck
2017-06-22 19:21     ` Benjamin Marzinski
2017-06-22 20:44       ` Martin Wilck [this message]
2017-06-21 15:15 ` [PATCH v3 00/11] multipath-tools: no_path_retry/queue_if_no_path/hwhandler logic Martin Wilck

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=1498164293.4743.3.camel@suse.com \
    --to=mwilck@suse.com \
    --cc=bmarzins@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=hare@suse.de \
    --cc=xose.vazquez@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox