<div class="zcontentRow"> <p>Hello, Hannes<br></p><p>The kernel didn't limit the dev_loss_tmo if fast_io_fail_tmo is 0.<br></p><p>But multipath did. Should I <span style="line-height: 21px;">leave it alone</span> and just revert this patch?</p><p>Thanks.</p><p><br></p><div><div class="zhistoryRow" style="display:block"><div class="zhistoryDes" style="width: 100%; height: 28px; line-height: 28px; background-color: #E0E5E9; color: #1388FF; text-align: center;" language-data="HistoryOrgTxt">原始邮件</div><div id="zwriteHistoryContainer"><div class="control-group zhistoryPanel"><div class="zhistoryHeader" style="padding: 8px; background-color: #F5F6F8;"><div><strong language-data="HistorySenderTxt">发件人:</strong><span class="zreadUserName">HannesReinecke</span></div><div><strong language-data="HistoryTOTxt">收件人:</strong><span class="zreadUserName" style="display: inline-block;"><dm-devel@redhat.com></span></div><div><strong language-data="HistoryDateTxt">日 期 :</strong><span class="">2016年12月07日 15:04</span></div><div><strong language-data="HistorySubjectTxt">主 题 :</strong><span class="zreadTitle"><strong>Re: [dm-devel] [PATCH] libmultipath: ensure dev_loss_tmo will be update to MAX_DEV_LOSS_TMO if no_path_retry set to queue</strong></span></div></div><p class="zhistoryContent"><br></p><div>On 12/07/2016 07:42 AM, peng.liang5@zte.com.cn wrote:<br>> Hello, Ben<br>> <br>> Sorry for late to reply.<br>> <br>> Such is the case as you said below. If fast_io_fail_tmo is off we have<br>> to cap dev_loss_tmo at 600. So, this patch is a wrong guide and will be<br>> cause a kernel error.<br>> <br>Indeed.<br><br>We've had _far_ too many fixes for the 'dev_loss_tmo defaults to 600'<br>issue, but seems to have it fixed by now.<br>So any patches in this area should be treated with utmost caution.<br><br>> And one more question. Should the system limit dev_loss_tmo to 600 if <br>> fast_io_fail_tmo set to 0?<br>> <br>There kernel surely does. And if there is no error in the current<br>algorithm I'm strongly in favour of just leave it alone.<br><br>Cheers,<br><br>Hannes<br><br>> On Thu, Dec 01, 2016 at 09:06:14AM +0800, peng.liang5@zte.com.cn wrote:<br>> >    If fast_io_fail_tmo isn't set, it will be use the DEFAULT_FAST_IO_FAIL<br>> >    in select_fast_io_fail.<br>> > <br>> >    So, multipath will not run the limited of dev_loss_tmo to 600.<br>> <br>> Yes, but the kernel will. With your patch installed, if I disable<br>> fast_io_fail_tmo and set no_path_retry to queue, I get these messages<br>> <br>> Dec 01 04:19:02 | rport-11:0-0: failed to set dev_loss_tmo to<br>> 2147483647, error 22<br>> <br>> Because if fast_io_fail_tmo is not set, the kernel itself will bar<br>> dev_loss_tmo from being above 600 seconds. Also, even if you could set<br>> dev_loss_tmo to it's maximum without fast_io_fail_tmo set, you would<br>> never want to, because you would break multipath.<br>> <br>> With fast_io_fail_tmo disabled, the scsi device will never pass the<br>> failed IO back up until dev_loss_tmo triggers.  This means that if you<br>> lose a path on your multipath device while doing IO, you won't be able<br>> to resend that IO down another path for 68 years (2147483647 seconds).<br>> Also, all the synchronous checker functions will not return for 648<br>> years. And during all this time these processes will be uninterruptable<br>> sleep. At that point, there would be no point to even having multiple<br>> paths, because you couldn't ever actually use them if one went down.<br>> <br>> > <br>> >    And I think using MP_FAST_IO_FAIL_UNSET as the condition is meaningless<br>> >    after multipath<br>> > <br>> >    run select_fast_io_fail even if it's not set.<br>> <br>> This is true in the default case, but we can't rely on the default case.<br>> Since we allow users to turn it off, we need to correctly configure<br>> multipath when it is off.<br>> <br>> -Ben<br>> <br>> >                                     原始邮件<br>> >    发件人:BenjaminMarzinski<br>> >    收件人:彭亮10137102;<br>> >    抄送人:<dm-devel@redhat.com>张凯10072500;<br>> >    日 期 :2016年11月29日 08:30<br>> >    主 题 :Re: [dm-<br>> devel] [PATCH] libmultipath: ensure dev_loss_tmo will be<br>> >    update to MAX_DEV_LOSS_TMO if no_path_retry set to queue<br>> > <br>> >    On Fri, Nov 25, 2016 at 02:36:04PM +0800, peng.liang5@zte.com.cn wrote:<br>> >    > From: PengLiang <peng.liang5@zte.com.cn><br>> >    > <br>> >    > If no_path_retry set to queue, we should make sure dev_loss_tmo update to MAX_DEV_LOSS_TMO.<br>> >    > But, it will be limit to 600 if fast_io_fail_tmo set to off or 0 meanwhile.<br>> > <br>> >    Doesn't the system still limit dev_loss_tmo to 600 if fast_io_fail_tmo isn't set. Multipath<br>> >    was using this limit, since the underlying system uses it.<br>> > <br>> >    -Ben<br>> > <br>> >    > <br>> >    > Signed-off-by: PengLiang <peng.liang5@zte.com.cn><br>> >    > ---<br>> >    >  libmultipath/discovery.c | 3 ++-<br>> >    >  1 file changed, 2 insertions(+), 1 deletion(-)<br>> >    > <br>> >    > diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c<br>> >    > index aaa915c..05b0842 100644<br>> >    > --- a/libmultipath/discovery.c<br>> >    > +++ b/libmultipath/discovery.c<br>> >    > @@ -608,7 +608,8 @@ sysfs_set_rport_tmo(struct multipath *mpp, struct path *pp)<br>> >    >                  goto out;<br>> >    >              }<br>> >    >          }<br>> >    > -    } else if (mpp->dev_loss > DEFAULT_DEV_LOSS_TMO) {<br>> >    > +    } else if (mpp->dev_loss > DEFAULT_DEV_LOSS_TMO &&<br>> >    > +        mpp->no_path_retry != NO_PATH_RETRY_QUEUE) {<br>> >    >          condlog(3, "%s: limiting dev_loss_tmo to %d, since "<br>> >    >              "fast_io_fail is not set",<br>> >    >              rport_id, DEFAULT_DEV_LOSS_TMO);<br>> >    > -- <br>> >    > 2.8.1.windows.1<br>> > <br>> >    --<br>> >    dm-devel mailing list<br>> >    dm-devel@redhat.com<br>> >    https://www.redhat.com/mailman/listinfo/dm-devel<br>> <br>> <br>> --<br>> dm-devel mailing list<br>> dm-devel@redhat.com<br>> https://www.redhat.com/mailman/listinfo/dm-devel<br>> <br>> <br>> <br>> <br>> <br>> --<br>> dm-devel mailing list<br>> dm-devel@redhat.com<br>> https://www.redhat.com/mailman/listinfo/dm-devel<br>> <br><br><br>-- <br>Dr. Hannes Reinecke           Teamlead Storage & Networking<br>hare@suse.de                           +49 911 74053 688<br>SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg<br>GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton<br>HRB 21284 (AG Nürnberg)<br><br>--<br>dm-devel mailing list<br>dm-devel@redhat.com<br>https://www.redhat.com/mailman/listinfo/dm-devel</div><p><br></p></div></div></div></div><p><br></p> </div>