<p dir="ltr">If your patch implement a direct path-to-multipath conflict error propagation, won't the common scenario where admins add new (initialy unregistered) paths to a reserved multipath result in application-visible i/o errors ? If so, those admins might hold us a grudge :/</p>
<p dir="ltr">For reference the opensvc crm does use type 5 pr, and aims for all paths registered. It still does not make use of the multipathd pr janitoring features, and uses sg_persist directly for pr status and actions.</p>
<p dir="ltr">Best regards,<br>
Christophe Varoqui <br>
OpenSVC </p>
<p dir="ltr">Regards,</p>
<p dir="ltr">Christophe Varoqui</p>
<p dir="ltr">OpenSVC</p>
<div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jul 15, 2015 at 1:35 PM, James Bottomley <span dir="ltr"><<a href="mailto:James.Bottomley@hansenpartnership.com" target="_blank">James.Bottomley@hansenpartnership.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On Wed, 2015-07-15 at 13:23 +0200, Hannes Reinecke wrote:<br>
> If dm-mpath encounters an reservation conflict it should not<br>
> fail the path (as communication with the target is not affected)<br>
> but should rather retry on another path.<br>
> However, in doing so we might be inducing a ping-pong between<br>
> paths, with no guarantee of any forward progress.<br>
> And arguably a reservation conflict is an unexpected error,<br>
> so we should be passing it upwards to allow the application<br>
> to take appropriate steps.<br>
<br>
</span>If I interpret the code correctly, you've changed the behaviour from the<br>
current try all paths and fail them, ultimately passing the reservation<br>
conflict up if all paths fail to return reservation conflict<br>
immediately, keeping all paths running.  This assumes that the<br>
reservation isn't path specific because if we encounter a path specific<br>
reservation, you've altered the behaviour from route around to fail.<br>
<br>
The case I think the original code was for is SAN Volume controllers<br>
which use path specific SCSI-3 reservations effectively to do traffic<br>
control and allow favoured paths.  Have you verified that nothing we<br>
encounter in the enterprise uses path specific reservations for<br>
multipath shaping any more?<br>
<span><font color="#888888"><br>
James<br>
</font></span><div><div><br>
> Signed-off-by: Hannes Reinecke <<a href="mailto:hare@suse.de" target="_blank">hare@suse.de</a>><br>
> ---<br>
>  drivers/md/dm-mpath.c | 14 ++++++++++----<br>
>  1 file changed, 10 insertions(+), 4 deletions(-)<br>
><br>
> diff --git a/drivers/md/dm-mpath.c b/drivers/md/dm-mpath.c<br>
> index 5a67671..e65d266 100644<br>
> --- a/drivers/md/dm-mpath.c<br>
> +++ b/drivers/md/dm-mpath.c<br>
> @@ -1269,7 +1269,16 @@ static int do_end_io(struct multipath *m, struct request *clone,<br>
>       if (noretry_error(error))<br>
>               return error;<br>
><br>
> -     if (mpio->pgpath)<br>
> +     /*<br>
> +      * EBADE signals an reservation conflict.<br>
> +      * We shouldn't fail the path here as we can communicate with<br>
> +      * the target. We should failover to the next path, but in<br>
> +      * doing so we might be causing a ping-pong between paths.<br>
> +      * So just return the reservation conflict error.<br>
> +      */<br>
> +     if (error == -EBADE)<br>
> +             r = error;<br>
> +     else if (mpio->pgpath)<br>
>               fail_path(mpio->pgpath);<br>
><br>
>       spin_lock_irqsave(&m->lock, flags);<br>
> @@ -1277,9 +1286,6 @@ static int do_end_io(struct multipath *m, struct request *clone,<br>
>               if (!m->queue_if_no_path) {<br>
>                       if (!__must_push_back(m))<br>
>                               r = -EIO;<br>
> -             } else {<br>
> -                     if (error == -EBADE)<br>
> -                             r = error;<br>
>               }<br>
>       }<br>
>       spin_unlock_irqrestore(&m->lock, flags);<br>
<br>
<br>
<br>
--<br>
</div></div><div><div>dm-devel mailing list<br>
<a href="mailto:dm-devel@redhat.com" target="_blank">dm-devel@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/dm-devel" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/dm-devel</a><br>
</div></div></blockquote></div><br></div>