Re: [PATCH 3/3] nvme-multipath: add "use_nonoptimized" module option

Sagi Grimberg
2023-09-27T11:31:44Z

>> Setting nvme_core.use_nonoptimized=true will cause the path
>> selector to treat optimized and nonoptimized paths equally.
>>
>> This is because although an NVMe fabrics target device may report
>> an unoptimized ANA state, it is possible that other factors such
>> as fabric latency are a large factor in the I/O service time.  And,
>> throughput may improve overall if nonoptimized ports are also used.
>>
>> Signed-off-by: Ewan D. Milne <emilne@redhat.com>
>> ---
>>   drivers/nvme/host/multipath.c | 22 +++++++++++++++++++---
>>   1 file changed, 19 insertions(+), 3 deletions(-)
>>
> No. Please don't.
>
> There's a reason why controllers specify paths as 'active/optimized' or
> 'active/non-optimized'. If they had wanted us to use all paths they
> would have put them into the same group.
> They tend to get very unhappy if you start using them at the same time.
> (Triggering failover etc.)

I have to agree here. This is effectively a modparam that says
all paths are optimized regardless of what the controller reports.

While I do acknowledge that there may be some merit to use non-optimized
paths as well, but its almost impossible to know some latent optimum
path distribution. Hence the host forfeits even attempting.

If the controller wants all path used, it should make all paths
optimized and the host can examine QD accumulating on some paths
vs others.