* [PATCHv3 0/4] nvme-cli: enhance the visibility of multipath using show-topology command
@ 2025-09-04 17:56 Nilay Shroff
0 siblings, 0 replies; 4+ messages in thread
From: Nilay Shroff @ 2025-09-04 17:56 UTC (permalink / raw)
To: linux-nvme; +Cc: dwagner, hare, kbusch, gjoyce
Hi,
There has been recent work to improve the visibility of NVMe multipath
configurations. The native NVMe multipath kernel driver supports three
I/O path selection policies: numa, round-robin, and queue-depth. However,
until now, users have had no insight into which path is selected by the
multipath logic for forwarding I/O.
To address this, an RFC was proposed [1] and has since been merged into
the Linux kernel as of v6.15. Following that, libnvme was extended to
discover multiple paths to a shared NVMe namespace [2]. This patchset
builds on those efforts to improve userspace observability of multipath
configurations via nvme-cli.
This patchset contains four patches:
The first patch in the series fixes a <device> filter option using which
we could be able to filter the output of nvme show-topology command.
The second patch in the series enhances the nvme show-topology command to
display multipath configuration, including all discovered paths to a
namespace, along with details such as ANA state, NUMA nodes, and queue
depth. The show-topology "--ranking" option is extended with a new sub-
option: multipath.
The third patch in the series adds common table APIs for printing nvme cli
command output in tabular format. With these APIs, developers no longer
need to pre-calculate column or row widths. The output is consistently
aligned and easy to read.
The fourth patch adds support for printing show-topology in tabular form
leveraging the introduced table APIs to produce well-aligned, easy-to-read
output.
As usual, any feedback/sugegstion is most welcome!
Thanks!
Changes from v2:
- For iopolicy=numa, print NUMA nodes and exclude queue-depth.
Similarly, for iopolicy=queue-depth, print queue-depth but exclude
NUMA nodes. And for iopolicy=round-robin, exclude printing
both NUMA nodes and queue-depth. (Hannes Reinecke, Daniel
Wagner)
Link to v2: https://lore.kernel.org/all/20250812125614.164445-1-nilay@linux.ibm.com/
Changes from v1:
- Added the third patch in the series that implements the common table
APIs for printing nvme cli command output in tabular format
(Daniel Wagner)
- Added the fourth patch in the series which adds the support for
printing show-topology in tabular form (Daniel Wagner)
Link to v1: https://lore.kernel.org/all/20250704135001.292763-1-nilay@linux.ibm.com/
Nilay Shroff (4):
nvme: support <device> option in show-topology command
nvme: extend show-topology command to add support for multipath
nvme: add common APIs for printing tabular format output
nvme: add support for printing show-topology in tabular form
nvme-print-binary.c | 1 +
nvme-print-json.c | 36 ++++-
nvme-print-stdout.c | 312 +++++++++++++++++++++++++++++++++++++++++-
nvme-print.c | 9 +-
nvme-print.h | 3 +
nvme.c | 29 +++-
nvme.h | 2 +
util/meson.build | 3 +-
util/table.c | 320 ++++++++++++++++++++++++++++++++++++++++++++
util/table.h | 149 +++++++++++++++++++++
10 files changed, 849 insertions(+), 15 deletions(-)
create mode 100644 util/table.c
create mode 100644 util/table.h
--
2.51.0
^ permalink raw reply [flat|nested] 4+ messages in thread* [PATCHv3 0/4] nvme-cli: enhance the visibility of multipath using show-topology command
@ 2025-09-04 17:56 Nilay Shroff
2025-09-21 12:11 ` Nilay Shroff
0 siblings, 1 reply; 4+ messages in thread
From: Nilay Shroff @ 2025-09-04 17:56 UTC (permalink / raw)
To: linux-nvme; +Cc: dwagner, hare, kbusch, gjoyce
Hi,
There has been recent work to improve the visibility of NVMe multipath
configurations. The native NVMe multipath kernel driver supports three
I/O path selection policies: numa, round-robin, and queue-depth. However,
until now, users have had no insight into which path is selected by the
multipath logic for forwarding I/O.
To address this, an RFC was proposed [1] and has since been merged into
the Linux kernel as of v6.15. Following that, libnvme was extended to
discover multiple paths to a shared NVMe namespace [2]. This patchset
builds on those efforts to improve userspace observability of multipath
configurations via nvme-cli.
This patchset contains four patches:
The first patch in the series fixes a <device> filter option using which
we could be able to filter the output of nvme show-topology command.
The second patch in the series enhances the nvme show-topology command to
display multipath configuration, including all discovered paths to a
namespace, along with details such as ANA state, NUMA nodes, and queue
depth. The show-topology "--ranking" option is extended with a new sub-
option: multipath.
The third patch in the series adds common table APIs for printing nvme cli
command output in tabular format. With these APIs, developers no longer
need to pre-calculate column or row widths. The output is consistently
aligned and easy to read.
The fourth patch adds support for printing show-topology in tabular form
leveraging the introduced table APIs to produce well-aligned, easy-to-read
output.
As usual, any feedback/sugegstion is most welcome!
Thanks!
Changes from v2:
- For iopolicy=numa, print NUMA nodes and exclude queue-depth.
Similarly, for iopolicy=queue-depth, print queue-depth but exclude
NUMA nodes. And for iopolicy=round-robin, exclude printing
both NUMA nodes and queue-depth. (Hannes Reinecke, Daniel
Wagner)
Link to v2: https://lore.kernel.org/all/20250812125614.164445-1-nilay@linux.ibm.com/
Changes from v1:
- Added the third patch in the series that implements the common table
APIs for printing nvme cli command output in tabular format
(Daniel Wagner)
- Added the fourth patch in the series which adds the support for
printing show-topology in tabular form (Daniel Wagner)
Link to v1: https://lore.kernel.org/all/20250704135001.292763-1-nilay@linux.ibm.com/
Nilay Shroff (4):
nvme: support <device> option in show-topology command
nvme: extend show-topology command to add support for multipath
nvme: add common APIs for printing tabular format output
nvme: add support for printing show-topology in tabular form
nvme-print-binary.c | 1 +
nvme-print-json.c | 36 ++++-
nvme-print-stdout.c | 312 +++++++++++++++++++++++++++++++++++++++++-
nvme-print.c | 9 +-
nvme-print.h | 3 +
nvme.c | 29 +++-
nvme.h | 2 +
util/meson.build | 3 +-
util/table.c | 320 ++++++++++++++++++++++++++++++++++++++++++++
util/table.h | 149 +++++++++++++++++++++
10 files changed, 849 insertions(+), 15 deletions(-)
create mode 100644 util/table.c
create mode 100644 util/table.h
--
2.51.0
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCHv3 0/4] nvme-cli: enhance the visibility of multipath using show-topology command
2025-09-04 17:56 Nilay Shroff
@ 2025-09-21 12:11 ` Nilay Shroff
2025-09-22 9:41 ` Daniel Wagner
0 siblings, 1 reply; 4+ messages in thread
From: Nilay Shroff @ 2025-09-21 12:11 UTC (permalink / raw)
To: Daniel Wagner; +Cc: hare, kbusch, gjoyce, linux-nvme@lists.infradead.org
Hi Daniel,
A gentle ping on this patchset. Please let me know, in case, if you've
any further query/comment/suggestion for this patchset.
Thanks,
--Nilay
On 9/4/25 11:26 PM, Nilay Shroff wrote:
> Hi,
>
> There has been recent work to improve the visibility of NVMe multipath
> configurations. The native NVMe multipath kernel driver supports three
> I/O path selection policies: numa, round-robin, and queue-depth. However,
> until now, users have had no insight into which path is selected by the
> multipath logic for forwarding I/O.
>
> To address this, an RFC was proposed [1] and has since been merged into
> the Linux kernel as of v6.15. Following that, libnvme was extended to
> discover multiple paths to a shared NVMe namespace [2]. This patchset
> builds on those efforts to improve userspace observability of multipath
> configurations via nvme-cli.
>
> This patchset contains four patches:
> The first patch in the series fixes a <device> filter option using which
> we could be able to filter the output of nvme show-topology command.
>
> The second patch in the series enhances the nvme show-topology command to
> display multipath configuration, including all discovered paths to a
> namespace, along with details such as ANA state, NUMA nodes, and queue
> depth. The show-topology "--ranking" option is extended with a new sub-
> option: multipath.
>
> The third patch in the series adds common table APIs for printing nvme cli
> command output in tabular format. With these APIs, developers no longer
> need to pre-calculate column or row widths. The output is consistently
> aligned and easy to read.
>
> The fourth patch adds support for printing show-topology in tabular form
> leveraging the introduced table APIs to produce well-aligned, easy-to-read
> output.
>
> As usual, any feedback/sugegstion is most welcome!
>
> Thanks!
>
> Changes from v2:
> - For iopolicy=numa, print NUMA nodes and exclude queue-depth.
> Similarly, for iopolicy=queue-depth, print queue-depth but exclude
> NUMA nodes. And for iopolicy=round-robin, exclude printing
> both NUMA nodes and queue-depth. (Hannes Reinecke, Daniel
> Wagner)
> Link to v2: https://lore.kernel.org/all/20250812125614.164445-1-nilay@linux.ibm.com/
>
> Changes from v1:
> - Added the third patch in the series that implements the common table
> APIs for printing nvme cli command output in tabular format
> (Daniel Wagner)
> - Added the fourth patch in the series which adds the support for
> printing show-topology in tabular form (Daniel Wagner)
> Link to v1: https://lore.kernel.org/all/20250704135001.292763-1-nilay@linux.ibm.com/
>
> Nilay Shroff (4):
> nvme: support <device> option in show-topology command
> nvme: extend show-topology command to add support for multipath
> nvme: add common APIs for printing tabular format output
> nvme: add support for printing show-topology in tabular form
>
> nvme-print-binary.c | 1 +
> nvme-print-json.c | 36 ++++-
> nvme-print-stdout.c | 312 +++++++++++++++++++++++++++++++++++++++++-
> nvme-print.c | 9 +-
> nvme-print.h | 3 +
> nvme.c | 29 +++-
> nvme.h | 2 +
> util/meson.build | 3 +-
> util/table.c | 320 ++++++++++++++++++++++++++++++++++++++++++++
> util/table.h | 149 +++++++++++++++++++++
> 10 files changed, 849 insertions(+), 15 deletions(-)
> create mode 100644 util/table.c
> create mode 100644 util/table.h
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCHv3 0/4] nvme-cli: enhance the visibility of multipath using show-topology command
2025-09-21 12:11 ` Nilay Shroff
@ 2025-09-22 9:41 ` Daniel Wagner
0 siblings, 0 replies; 4+ messages in thread
From: Daniel Wagner @ 2025-09-22 9:41 UTC (permalink / raw)
To: Nilay Shroff; +Cc: hare, kbusch, gjoyce, linux-nvme@lists.infradead.org
Hi Nilay,
On Sun, Sep 21, 2025 at 05:41:59PM +0530, Nilay Shroff wrote:
> A gentle ping on this patchset. Please let me know, in case, if you've
> any further query/comment/suggestion for this patchset.
All good, I've applied the series. FTR, the tabular output looks nice:
nvme-subsys29 - NQN=nqn.1992-08.com.netapp:sn.44ede5aaa52511e8abb200a09890f5bf:subsystem.nvme-svm-dolin-qla-subsystem
hostnqn=nqn.2014-08.org.nvmexpress:uuid:31333937-3136-584d-5135-323430365637
iopolicy=queue-depth
NSHead NSID NSPath ANAState Qdepth Controller TrType Address State
-------- ---- ----------- ------------- ------ ---------- ------ ---------------------------------------------------------------------------------------------------------- -----
nvme29n1 2 nvme29c11n1 optimized 0 nvme11 fc traddr=nn-0x200200a09890f5bf:pn-0x203600a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 2 nvme29c29n1 optimized 0 nvme29 fc traddr=nn-0x200200a09890f5bf:pn-0x203800a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 2 nvme29c30n1 non-optimized 0 nvme30 fc traddr=nn-0x200200a09890f5bf:pn-0x203700a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 2 nvme29c31n1 non-optimized 0 nvme31 fc traddr=nn-0x200200a09890f5bf:pn-0x203900a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 2 nvme29c32n1 non-optimized 0 nvme32 fc traddr=nn-0x200200a09890f5bf:pn-0x203700a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 2 nvme29c33n1 optimized 0 nvme33 fc traddr=nn-0x200200a09890f5bf:pn-0x203800a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 2 nvme29c34n1 non-optimized 0 nvme34 fc traddr=nn-0x200200a09890f5bf:pn-0x203900a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 2 nvme29c35n1 optimized 0 nvme35 fc traddr=nn-0x200200a09890f5bf:pn-0x203600a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
nvme29n2 1 nvme29c11n2 optimized 0 nvme11 fc traddr=nn-0x200200a09890f5bf:pn-0x203600a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 1 nvme29c29n2 optimized 0 nvme29 fc traddr=nn-0x200200a09890f5bf:pn-0x203800a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 1 nvme29c30n2 non-optimized 0 nvme30 fc traddr=nn-0x200200a09890f5bf:pn-0x203700a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 1 nvme29c31n2 non-optimized 0 nvme31 fc traddr=nn-0x200200a09890f5bf:pn-0x203900a09890f5bf,host_traddr=nn-0x20000024ff7fa448:pn-0x21000024ff7fa448 live
--> 1 nvme29c32n2 non-optimized 0 nvme32 fc traddr=nn-0x200200a09890f5bf:pn-0x203700a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 1 nvme29c33n2 optimized 0 nvme33 fc traddr=nn-0x200200a09890f5bf:pn-0x203800a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 1 nvme29c34n2 non-optimized 0 nvme34 fc traddr=nn-0x200200a09890f5bf:pn-0x203900a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
--> 1 nvme29c35n2 optimized 0 nvme35 fc traddr=nn-0x200200a09890f5bf:pn-0x203600a09890f5bf,host_traddr=nn-0x20000024ff7fa449:pn-0x21000024ff7fa449 live
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-09-22 9:41 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-04 17:56 [PATCHv3 0/4] nvme-cli: enhance the visibility of multipath using show-topology command Nilay Shroff
-- strict thread matches above, loose matches on Subject: below --
2025-09-04 17:56 Nilay Shroff
2025-09-21 12:11 ` Nilay Shroff
2025-09-22 9:41 ` Daniel Wagner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox