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 5FF821FF142 for ; Fri, 05 Jun 2026 17:39:33 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 7743C1F129; Fri, 5 Jun 2026 17:39:05 +0200 (CEST) From: =?UTF-8?q?Michael=20K=C3=B6ppl?= To: pve-devel@lists.proxmox.com Subject: [PATCH cluster/docs/manager/widget-toolkit v4 0/8] add warning messages for high token timeouts in clusters Date: Fri, 5 Jun 2026 17:38:11 +0200 Message-ID: <20260605153819.310048-1-m.koeppl@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1780673865877 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.091 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 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: W2URIYQQ2BUZUG3NWCS77PLNQIGWU5WD X-Message-ID-Hash: W2URIYQQ2BUZUG3NWCS77PLNQIGWU5WD X-MailFrom: m.koeppl@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: This patch series introduces warnings informing users about high token timeouts in their clusters. A recent change [0] lowered the token coefficient for clusters and allowed adapting it. However, this change only affects new clusters. As described in [1], users with existing cluster should be informed about the high token timeouts in their configurations and what they can do to alleviate this problem. Thus, warnings are added to the `pvecm status` command as well as to the cluster join info dialog in the web UI. The warning in the web UI warns users about the effect adding another node would have to allow them to make an informed change before adding another node. changes since v3 (thanks to @Fabian, @Friedrich for the feedback): - Rebase on latest master for all affected repos - Adapt the scan_extjs_file function to allow detecting `get_help_link` function calls across multiple lines - Move up the paragraph in the documentation to better fit in the updated section - Use the output of `corosync-cmapctl` to the token and consensus timeouts instead of re-implementing the calculation. This also means that, at least for now, the calculation can only be done for the current number of nodes, to avoid making the calculation more complex than it needs to be. This is based on feedback [2] on v3. - Instead of implementing the calculation of warning levels and messages twice (in pve-cluster and pve-manager separately), add a warnings property to the join info endpoint that consists of an array of objects with a type, level, and message field. The warning level and message are then constructed in pve-cluster, returned by the join info endpoint and only displayed by pve-manager. The ClusterEdit dialog can now display arbitrary warnings with their levels. The type field was added to be able to link to specific parts of the documentation for specific errors. This is based on feedback [2] from v4. - Add a patch to proxmox-widget-toolkit that adds a .pmx-critical CSS class that is similar to .pmx-hint, but for more critical errors. This was done based on the off-list suggestion by @Fabian that different warnings levels might warrant different colors in this case. Also, thanks to @Lukas for testing v3! changes since v2 (thanks to @Lukas and @Friedrich for the feedback): - use "lowering" instead of "changing" for the warning strings - replace leftover hard-coded PVE docs link with `man pvecm` - update descriptions of timeout_warning_level and expected_timeout params such that they say "membership recovery timeout", to more clearly state which timeout this is about - update function names for get_timeout_warning_level and get_timeout_warning to calculate_membership_recovery_timeout_warning_level and calculate_membership_recovery_timeout_warning respectively changes since v1 (thanks to @Friedrich for the feedback on v1): - add pve-docs patch to allow using get_help_link to directly link to an anchor in the local documentation (then used to link to the section on changing the token coefficient) - add pve-docs patch to define explicit anchor for the "Changing the Token Coefficient" section - add pve-docs patch extending the section for Changing the Token Coefficient slightly, informing users of the potential warning messages in the pvecm status output - change the threshold for "strongly recommend" from 50s to 45s as suggested by @Friedrich - adapted the name of calculate_total_timeout to calculate_membership_recovery_timeout - adapted commit messages for preparatory pve-manager patch (no functional changes intended) - moved the warning message in pvecm from `pvecm nodes` to `pvecm status` - replaced the URL in the pvecm warning message with a reference to the pvecm man pages - link to local documentation in ClusterEdit.js [0] https://git.proxmox.com/?p=pve-cluster.git;a=commit;h=a7b1c765b9223a81fb2dc4f072d6a6c095583cda [1] https://bugzilla.proxmox.com/show_bug.cgi?id=7398 [2] https://lore.proxmox.com/pve-devel/1779112787.r3e8af5igi.astroid@yuna.none/ pve-docs: Michael Köppl (2): asciidoc-pve: allow linking sections with get_help_link pvecm: add info about warnings regarding token coefficient pvecm.adoc | 5 +++++ scripts/asciidoc-pve.in | 19 ++++++++++--------- 2 files changed, 15 insertions(+), 9 deletions(-) pve-cluster: Michael Köppl (3): add functions to determine warning level for high token timeouts pvecm: warn users of high token timeouts when using status command api: join info: add totem timeout warning message and level src/PVE/API2/ClusterConfig.pm | 21 +++++++++++++ src/PVE/CLI/pvecm.pm | 7 +++++ src/PVE/Corosync.pm | 59 +++++++++++++++++++++++++++++++++++ 3 files changed, 87 insertions(+) proxmox-widget-toolkit: Michael Köppl (1): add pmx-critical CSS class src/css/ext6-pmx.css | 4 ++++ src/proxmox-dark/scss/proxmox/_general.scss | 15 +++++++++++---- 2 files changed, 15 insertions(+), 4 deletions(-) pve-manager: Michael Köppl (2): ui: cluster info: move initialization of items to initComponent ui: cluster info: display warnings from the join info endpoint www/manager6/dc/Cluster.js | 3 + www/manager6/dc/ClusterEdit.js | 140 ++++++++++++++++++++++----------- 2 files changed, 95 insertions(+), 48 deletions(-) Summary over all repositories: 9 files changed, 212 insertions(+), 61 deletions(-) -- Generated by murpp 0.11.0