From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH v3 manager 15/18] ui: node san: list NVMe over Fabrics controllers
Date: Sun, 22 Nov 2026 02:25:52 +0100 [thread overview]
Message-ID: <20261122012605.1848824-16-t.lamprecht@proxmox.com> (raw)
In-Reply-To: <20261122012605.1848824-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 | 152 +++++++++++++++++++++++++
5 files changed, 167 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 d28285d22..abff7f458 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..cad9b4cbc
--- /dev/null
+++ b/www/manager6/node/NVMeOFControllers.js
@@ -0,0 +1,152 @@
+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: 100 },
+ {
+ text: gettext('Subsystem'),
+ dataIndex: 'subsysnqn',
+ flex: 5,
+ 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: 180, renderer: Ext.htmlEncode },
+ {
+ text: gettext('State'),
+ dataIndex: 'state',
+ width: 150,
+ renderer: PVE.SANUtils.renderState,
+ },
+ { text: gettext('Namespaces'), dataIndex: 'namespaces', width: 110 },
+ {
+ text: gettext('Storage'),
+ dataIndex: 'used-by-storage',
+ flex: 1,
+ renderer: Ext.htmlEncode,
+ },
+ ],
+
+ 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.tbar = [
+ { 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(),
+ }),
+ }),
+ },
+ '->',
+ {
+ 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()),
+ },
+ ];
+ me.dockedItems = [
+ {
+ xtype: 'component',
+ itemId: 'warning',
+ dock: 'top',
+ padding: 5,
+ hidden: true,
+ },
+ ];
+ me.callParent();
+ },
+});
next prev parent reply other threads:[~2026-11-22 1:28 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-22 1:25 [PATCH v3 storage,docs,manager 00/18] NVMe over Fabrics storage Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 01/18] diskmanage: skip SMART queries for NVMe fabric namespaces Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 02/18] nvmeof: add a storage for NVMe over Fabrics subsystems Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 03/18] lvm: allow a volume group on an NVMe over Fabrics namespace Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 04/18] api: scan: add NVMe over Fabrics discovery Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 05/18] pvesm: add a scan command for NVMe over Fabrics Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 06/18] api: san luns: attribute NVMe namespaces to storage Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 07/18] api: add node-level NVMe over Fabrics status and controller removal Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 08/18] multipath: report the NVMe host NQN of each node Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 storage 09/18] multipath: report NVMe over Fabrics namespaces in the cluster status Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 docs 10/18] storage: document NVMe over Fabrics storages Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 11/18] report: add the NVMe over Fabrics host NQN and subsystems Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 12/18] ui: storage: add NVMe over Fabrics storage Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 13/18] ui: lvm: offer NVMe over Fabrics storages as base storage Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 14/18] ui: storage: add a guided setup for shared LVM on NVMe over Fabrics Thomas Lamprecht
2026-11-22 1:25 ` Thomas Lamprecht [this message]
2026-11-22 1:25 ` [PATCH v3 manager 16/18] ui: san: show the NVMe host NQN of each node Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 17/18] ui: san: show that a namespace uses native multipath Thomas Lamprecht
2026-11-22 1:25 ` [PATCH v3 manager 18/18] pvestatd: notify on NVMe over Fabrics namespaces as on multipath maps Thomas Lamprecht
2026-11-23 2:02 ` superseded: [PATCH v3 storage,docs,manager 00/18] NVMe over Fabrics storage 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=20261122012605.1848824-16-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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.