From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [IPv6:2a0f:8001:1:32::40]) by lore.proxmox.com (Postfix) with ESMTPS id CA3781FF0B3 for ; Wed, 28 Oct 2026 10:58:33 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 71E3F214DA; Wed, 28 Oct 2026 10:58:25 +0100 (CET) From: Kefu Chai To: pve-devel@lists.proxmox.com Subject: [PATCH cluster/manager 0/2] fix #6501: allow cluster names up to 32 characters Date: Wed, 28 Oct 2026 17:58:09 +0800 Message-ID: <20261028095811.2408095-1-k.chai@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1793181494570 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.287 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: CN3H7TKEGGPYRUI52FG534K66YUTF7IJ X-Message-ID-Hash: CN3H7TKEGGPYRUI52FG534K66YUTF7IJ X-MailFrom: k.chai@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: The cluster name is limited to 15 characters. The limit dates back to 2011, when clusters ran on cman. corosync 3, corosync-qdevice and pmxcfs handle longer names, so this series raises the limit to 32, in the cluster create API (pve-cluster) and in the create dialog (pve-manager). The allowed characters stay the same. On master and on stable-bookworm (pve-cluster 8.1), the name is only checked when a cluster is created. Joining a node copies corosync.conf as is, and parse_conf, pmxcfs and qnetd don't limit the name. So older nodes, including ones that join later, should work with a longer name, and so should a downgrade. The reporter also says a longer name set in corosync.conf by hand works for them. On a single node, the two packages can be upgraded in either order: - new pve-cluster, old pve-manager: the GUI still stops at 15, while pvecm and the API take 32 - old pve-cluster, new pve-manager: the GUI takes 32, but the API rejects anything over 15 ("value may only be 15 characters long") before creating anything The second case is confusing but harmless. Bumping pve-manager's dependency on libpve-cluster-api-perl, which ships the API, would avoid it. With a QDevice, the name is also the CN of the cluster's certificate, which qnetd checks. RFC 5280 limits a CN to 64 characters, so 32 is fine. I tested this on a three-node lab cluster. The API accepts a 32-character name and rejects 33. After I renamed the cluster to a 32-character name in corosync.conf, it stayed quorate, and pmxcfs, pvecm status and the cluster status and join info APIs showed the new name. I couldn't test a join or mixed versions there, so that part is from reading the code. Please let me know if I missed something. pve-cluster: Kefu Chai (1): fix #6501: api: cluster create: allow cluster names up to 32 characters src/PVE/API2/ClusterConfig.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) pve-manager: Kefu Chai (1): fix #6501: ui: cluster create: allow cluster names up to 32 characters www/manager6/dc/ClusterEdit.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.47.3