From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id 83F101FF17A for ; Tue, 11 Nov 2025 17:56:09 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id EA7FC1133D; Tue, 11 Nov 2025 17:56:53 +0100 (CET) Message-ID: <63f8a09b-20a2-4282-a3f1-30aa7887e3c5@proxmox.com> Date: Tue, 11 Nov 2025 17:56:42 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Friedrich Weber To: Proxmox VE development discussion , Mira Limbeck References: <20251110170124.3460419-1-m.limbeck@proxmox.com> Content-Language: en-US In-Reply-To: <20251110170124.3460419-1-m.limbeck@proxmox.com> X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1762880178899 X-SPAM-LEVEL: Spam detection results: 0 AWL -0.137 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment POISEN_SPAM_PILL 0.1 Meta: its spam POISEN_SPAM_PILL_1 0.1 random spam to be learned in bayes POISEN_SPAM_PILL_3 0.1 random spam to be learned in bayes RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: Re: [pve-devel] [RFC cluster/manager/storage 0/4] add storage mapping support X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox VE development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" On 10/11/2025 18:01, Mira Limbeck wrote: > This RFC is the first draft of storage mapping support. It > includes a reworked iSCSI plugin that handles storage mapping, as well > as an API to get/create/delete mappings. > > Some features are not yet implemented, for example reachability checks > for iSCSI. > The pve-manager patches are limited to the API, no UI exists for now. > > The idea would be to make it easy for iSCSI storages to use local > mappings that are managed through the GUI. > For this we would need to check the reachability of all announced > portals for each node. > This will be the next step after the basic mapping support. > > For now only an iSCSI plugin exists, but this could be extended to other > (future) storages as well. As such the idea is to have a generic base. Thanks for tackling this! I tested it a bit with a LIO target with multiple portals and targets exposing the same LUN. Took me a little to figure out how to add a mapping, so documenting this here just in case someone (including me) needs it again. For an existing iscsi storage: - pvesh create /cluster/mapping/storage/myiscsi --id myiscsi --type iscsi - pvesm set iscsi -mapping myiscsi - pvesh set /cluster/mapping/storage/myiscsi --type iscsi --map 'node=pve9-iscsi172,portals=10.1.1.134,target=iqn.2003-01.org.linux-iscsi.iscsi-target134.x8664:sn.940ff597178c' \ --map 'node=pve9-iscsi172,portals=10.3.1.134,target=iqn.2003-01.org.linux-iscsi.iscsi-target134.x8664:sn.b404625a505a' \ --map 'node=pve9-iscsi172,portals=10.2.1.134,target=iqn.2003-01.org.linux-iscsi.iscsi-target134.x8664:sn.940ff597178c' \ --map 'node=pve9-iscsi173,portals=10.1.1.134,target=iqn.2003-01.org.linux-iscsi.iscsi-target134.x8664:sn.940ff597178c' Works nicely so far! A couple of things I noticed (also briefly discussed with Mira off-list, noting this here for posterity): - I initially had a typo in my mapping and just got 'storage iscsi is not online', would be nice if there could be a more specific error/warning if no mapping entry matches on a given node. - looks like, with a mapping, there is no automatic discovery anymore. Hence, after deleting all discovery records (`iscsiadm -m node` is empty), the logins don't work because a discovery first has to populate the discovery records. Would be nice if the plugin could do discovery when needed. - one possible usecase would be to allow removing a portal from the mapping before disabling the portal target-side. However, currently, after removing the portal from the mapping, there would still be an open session to the portal, which can cause issues if the portal is disabled target-side. In this case, it might be nice if the iSCSI plugin would automatically log out from logged-in sessions that don't match any entry in the mapping? Not sure if this is something we always want, though? _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel