From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH v5 manager 22/26] ui: node san: list NVMe over Fabrics controllers
Date: Mon, 23 Nov 2026 14:32:14 +0100 [thread overview]
Message-ID: <20261123133412.3710030-23-t.lamprecht@proxmox.com> (raw)
In-Reply-To: <20261123133412.3710030-1-t.lamprecht@proxmox.com>
Add a view below Node > SAN with the controllers of a node, one per
connected portal, with their transport, state and storage, and the host
NQN of the node. A controller can be disconnected there, for example
after its portal was removed from the storage, which the node refuses
for the last usable path of a namespace in use. The controllers come
from sysfs, so the view lists them also without nvme-cli, which only
Disconnect needs.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
---
www/manager6/Makefile | 1 +
www/manager6/SANUtils.js | 5 +
www/manager6/Utils.js | 1 +
www/manager6/node/Config.js | 9 +-
www/manager6/node/NVMeOFControllers.js | 175 +++++++++++++++++++++++++
5 files changed, 190 insertions(+), 1 deletion(-)
create mode 100644 www/manager6/node/NVMeOFControllers.js
diff --git a/www/manager6/Makefile b/www/manager6/Makefile
index f2fc80279..f3591e1c8 100644
--- a/www/manager6/Makefile
+++ b/www/manager6/Makefile
@@ -253,6 +253,7 @@ JSSRC= \
node/ISCSITargets.js \
node/LVM.js \
node/LVMThin.js \
+ node/NVMeOFControllers.js \
node/SANLuns.js \
node/StatusView.js \
node/Subscription.js \
diff --git a/www/manager6/SANUtils.js b/www/manager6/SANUtils.js
index bd1c87324..96e099059 100644
--- a/www/manager6/SANUtils.js
+++ b/www/manager6/SANUtils.js
@@ -132,6 +132,11 @@ Ext.define('PVE.SANUtils', {
'logged-in': ['check-circle good', gettext('Connected')],
recovering: ['exclamation-circle warning', gettext('Reconnecting')],
'not-connected': ['times-circle faded', gettext('Not connected')],
+ live: ['check-circle good', gettext('Connected')],
+ connecting: ['exclamation-circle warning', gettext('Reconnecting')],
+ resetting: ['exclamation-circle warning', gettext('Reconnecting')],
+ deleting: ['times-circle faded', gettext('Disconnecting')],
+ 'deleting (no IO)': ['times-circle faded', gettext('Disconnecting')],
}[state];
let [icon, label] = display ?? ['question-circle faded', state];
return `<i class="fa fa-fw fa-${icon}"></i> ${Ext.htmlEncode(text ?? label)}`;
diff --git a/www/manager6/Utils.js b/www/manager6/Utils.js
index d508d0469..fc3667f51 100644
--- a/www/manager6/Utils.js
+++ b/www/manager6/Utils.js
@@ -2276,6 +2276,7 @@ Ext.define('PVE.Utils', {
lvmthinremove: ['Thinpool', gettext('Remove')],
migrateall: ['', gettext('Bulk migrate VMs and Containers')],
move_volume: ['CT', gettext('Move Volume')],
+ nvmedisconnect: ['NVMe-oF', gettext('Disconnect')],
'pbs-download': ['VM/CT', gettext('File Restore Download')],
pull_file: ['CT', gettext('Pull file')],
push_file: ['CT', gettext('Push file')],
diff --git a/www/manager6/node/Config.js b/www/manager6/node/Config.js
index c85183766..830e8542a 100644
--- a/www/manager6/node/Config.js
+++ b/www/manager6/node/Config.js
@@ -398,7 +398,7 @@ Ext.define('PVE.node.Config', {
);
}
- // the LUN and iSCSI reads of the node accept either privilege
+ // the LUN, iSCSI and NVMe over Fabrics reads of the node accept either privilege
if (caps.nodes['Sys.Audit'] || caps.storage['Datastore.Allocate']) {
me.items.push(
{
@@ -414,6 +414,13 @@ Ext.define('PVE.node.Config', {
iconCls: 'fa fa-bullseye',
groups: ['san'],
},
+ {
+ xtype: 'pveNVMeOFControllerList',
+ title: 'NVMe over Fabrics',
+ itemId: 'san-nvmeof',
+ iconCls: 'fa fa-plug',
+ groups: ['san'],
+ },
);
}
diff --git a/www/manager6/node/NVMeOFControllers.js b/www/manager6/node/NVMeOFControllers.js
new file mode 100644
index 000000000..cc62d3419
--- /dev/null
+++ b/www/manager6/node/NVMeOFControllers.js
@@ -0,0 +1,175 @@
+Ext.define('PVE.node.NVMeOFControllerList', {
+ extend: 'Ext.grid.Panel',
+ xtype: 'pveNVMeOFControllerList',
+ onlineHelp: 'storage_nvmeof',
+ emptyText: gettext('No NVMe over Fabrics controllers found'),
+ viewConfig: { enableTextSelection: true },
+ store: {
+ fields: [
+ 'controller',
+ 'transport',
+ 'subsysnqn',
+ 'portal',
+ 'state',
+ 'namespaces',
+ 'used-by-storage',
+ ],
+ sorters: ['subsysnqn', 'portal'],
+ },
+ columns: [
+ { text: gettext('Controller'), dataIndex: 'controller', width: 85 },
+ {
+ text: gettext('Subsystem'),
+ dataIndex: 'subsysnqn',
+ flex: 3,
+ minWidth: 200,
+ renderer: Ext.htmlEncode,
+ },
+ {
+ text: gettext('Transport'),
+ dataIndex: 'transport',
+ width: 90,
+ // the transport of the controller, named as for the paths of a namespace
+ renderer: (value) => PVE.SANUtils.renderSanTransport(value && `nvme-${value}`),
+ },
+ { text: gettext('Portal'), dataIndex: 'portal', width: 150, renderer: Ext.htmlEncode },
+ {
+ text: gettext('State'),
+ dataIndex: 'state',
+ width: 120,
+ renderer: PVE.SANUtils.renderState,
+ },
+ {
+ text: gettext('Storage'),
+ dataIndex: 'used-by-storage',
+ flex: 1,
+ minWidth: 120,
+ renderer: Ext.htmlEncode,
+ },
+ {
+ text: gettext('Namespaces'),
+ tooltip: gettext('Namespaces of the subsystem that use native NVMe multipath'),
+ dataIndex: 'namespaces',
+ width: 100,
+ },
+ ],
+
+ reload: function () {
+ let me = this;
+ let load = (path, success) =>
+ Proxmox.Utils.API2Request({
+ url: `/nodes/${me.nodename}/san/nvmeof/${path}`,
+ method: 'GET',
+ waitMsgTarget: me.getView(),
+ failure: (response) =>
+ Proxmox.Utils.setErrorMask(me.getView(), response.htmlStatus),
+ success: (response) => !me.destroyed && success(response.result.data),
+ });
+ load('status', function (status) {
+ me.down('#hostnqn').setValue(status['host-nqn'] || '');
+ me.supported = !!status.supported;
+ let error = status.supported
+ ? status.error
+ : gettext('nvme-cli is not installed on this node.');
+ // the controllers come from sysfs, which needs neither nvme-cli nor a host identity
+ let warning = me.down('#warning');
+ warning.setHtml(
+ error
+ ? `<i class="fa fa-fw fa-exclamation-triangle warning"></i> ${Ext.htmlEncode(error)}`
+ : '',
+ );
+ warning.setHidden(!error);
+ load('controller', function (controllers) {
+ Proxmox.Utils.setErrorMask(me.getView(), false);
+ me.getStore().setData(controllers);
+ });
+ });
+ },
+
+ listeners: {
+ activate: function () {
+ this.reload();
+ },
+ },
+
+ initComponent: function () {
+ let me = this;
+ me.nodename = me.pveSelNode.data.node;
+ me.dockedItems = [
+ {
+ xtype: 'toolbar',
+ dock: 'top',
+ items: [
+ {
+ text: gettext('Reload'),
+ iconCls: 'fa fa-refresh',
+ handler: () => me.reload(),
+ },
+ {
+ xtype: 'proxmoxButton',
+ text: gettext('Disconnect'),
+ iconCls: 'fa fa-unlink',
+ disabled: true,
+ dangerous: true,
+ // the disconnect uses nvme-cli
+ enableFn: () =>
+ !!Ext.state.Manager.get('GuiCap').dc['Sys.Modify'] && me.supported,
+ confirmMsg: (rec) =>
+ Ext.String.format(
+ gettext(
+ 'Disconnect controller {0} from portal {1}? A storage that still lists that portal connects to it again.',
+ ),
+ Ext.htmlEncode(rec.get('controller')),
+ Ext.htmlEncode(rec.get('portal')),
+ ),
+ handler: (button, event, rec) =>
+ Proxmox.Utils.API2Request({
+ // refused if the kernel reused the controller number meanwhile
+ url:
+ `/nodes/${me.nodename}/san/nvmeof/controller/${rec.get('controller')}?` +
+ Ext.Object.toQueryString({
+ subsysnqn: rec.get('subsysnqn'),
+ portal: rec.get('portal'),
+ }),
+ method: 'DELETE',
+ waitMsgTarget: me,
+ failure: (response) =>
+ Ext.Msg.alert(gettext('Error'), response.htmlStatus),
+ success: (response) =>
+ Ext.create('Proxmox.window.TaskProgress', {
+ upid: response.result.data,
+ autoShow: true,
+ taskDone: () => !me.destroyed && me.reload(),
+ }),
+ }),
+ },
+ ],
+ },
+ {
+ // a host NQN does not fit next to the buttons on a narrow screen
+ xtype: 'toolbar',
+ dock: 'top',
+ items: [
+ {
+ xtype: 'displayfield',
+ itemId: 'hostnqn',
+ fieldLabel: gettext('Host NQN'),
+ },
+ {
+ iconCls: 'fa fa-clipboard',
+ tooltip: gettext('Copy to Clipboard'),
+ handler: () => PVE.Utils.copyToClipboard(me.down('#hostnqn').getValue()),
+ },
+ ],
+ },
+ {
+ xtype: 'component',
+ itemId: 'warning',
+ dock: 'top',
+ padding: 5,
+ hidden: true,
+ },
+ ];
+ me.callParent();
+ },
+});
next prev parent reply other threads:[~2026-11-23 13:37 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-23 13:31 applied: [PATCH v5 storage,docs,manager 00/26] NVMe over Fabrics storage Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 01/26] api: config: activate a new storage without holding the lock Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 02/26] diskmanage: skip SMART queries for NVMe fabric namespaces Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 03/26] diskmanage: list NVMe namespaces attached over TCP or RDMA for SAN only Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 04/26] api: disks: refuse a local wipe of a network NVMe namespace Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 05/26] nvmeof: add a storage for NVMe over Fabrics subsystems Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 06/26] d/control: bump pve-common for plain parameter error names Thomas Lamprecht
2026-11-23 13:31 ` [PATCH v5 storage 07/26] api: config: check the cluster version before the first nvmeof storage Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 08/26] lvm: allow a volume group on an NVMe over Fabrics namespace Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 09/26] api: scan: add NVMe over Fabrics discovery Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 10/26] pvesm: add a scan command for NVMe over Fabrics Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 11/26] api: san luns: attribute NVMe namespaces to storage Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 12/26] api: add node-level NVMe over Fabrics status and controller removal Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 13/26] multipath: report the NVMe host NQN of each node Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 14/26] multipath: report NVMe over Fabrics namespaces in the cluster status Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 storage 15/26] d/control: break pve-manager versions without namespace notifications Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 docs 16/26] storage: document NVMe over Fabrics storages Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 17/26] report: add the NVMe over Fabrics host NQN and subsystems Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 18/26] ui: storage: add NVMe over Fabrics storage Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 19/26] ui: lvm: offer NVMe over Fabrics storages as base storage Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 20/26] ui: storage: SAN setup: ignore spaces around a typed portal Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 21/26] ui: storage: add a guided setup for shared LVM on NVMe over Fabrics Thomas Lamprecht
2026-11-23 13:32 ` Thomas Lamprecht [this message]
2026-11-23 13:32 ` [PATCH v5 manager 23/26] ui: san: show the NVMe host NQN of each node Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 24/26] ui: san: show that a namespace uses native multipath Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 25/26] pvestatd: notify on NVMe over Fabrics namespaces as on multipath maps Thomas Lamprecht
2026-11-23 13:32 ` [PATCH v5 manager 26/26] d/control: bump versioned dependencies for NVMe over Fabrics Thomas Lamprecht
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=20261123133412.3710030-23-t.lamprecht@proxmox.com \
--to=t.lamprecht@proxmox.com \
--cc=pve-devel@lists.proxmox.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