From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id 5B7F71FF09C for ; Mon, 02 Nov 2026 16:20:53 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id E58EC21BB1; Mon, 02 Nov 2026 16:19:46 +0100 (CET) From: Hannes Laimer To: pve-devel@lists.proxmox.com Subject: [PATCH pve-manager v5 13/15] sdn: bring up the DHCP backends at boot before the guests start Date: Mon, 2 Nov 2026 16:18:40 +0100 Message-ID: <20261102151842.1605234-14-h.laimer@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20261102151842.1605234-1-h.laimer@proxmox.com> References: <20261102151842.1605234-1-h.laimer@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1793632739458 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.342 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: OIMIED6BTI3FPNM3XFFPKVZLQRPQZ6R7 X-Message-ID-Hash: OIMIED6BTI3FPNM3XFFPKVZLQRPQZ6R7 X-MailFrom: h.laimer@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 eBPF DHCP responder keeps its programs and maps pinned in bpffs, so they are gone after a reboot. The SDN commit helper now brings the DHCP backends back up on every boot, not only when it has changes to commit. The helper runs before the node and HA start the guests at boot. Otherwise the first guest interface plug loads the responder with a full pass, which holds the responder's lock exclusively. A guest starting meanwhile waits for that lock. One that waits too long comes up without the responder on its interface. Signed-off-by: Hannes Laimer --- Notes: v4: * log that the DHCP backends are being brought up bin/pve-sdn-commit | 4 ++++ services/pve-sdn-commit.service | 1 + 2 files changed, 5 insertions(+) diff --git a/bin/pve-sdn-commit b/bin/pve-sdn-commit index aa7e9b29056a..13231e4f4fd2 100644 --- a/bin/pve-sdn-commit +++ b/bin/pve-sdn-commit @@ -96,6 +96,10 @@ sub sdn_changed { return fabrics_changed(); } +# the dhcp backends bring back what a reboot took, pending changes or not +print "bringing up the DHCP backends\n"; +PVE::Network::SDN::Dhcp::boot(); + if (!sdn_changed()) { print "No changes to SDN configuration detected, skipping reload\n"; exit 0; diff --git a/services/pve-sdn-commit.service b/services/pve-sdn-commit.service index ff723725ddcd..825926be81bf 100644 --- a/services/pve-sdn-commit.service +++ b/services/pve-sdn-commit.service @@ -3,6 +3,7 @@ Description=Commit Proxmox VE SDN changes DefaultDependencies=no Wants=pve-cluster.service network.target After=frr.service network.target corosync.service +Before=pve-guests.service pve-ha-lrm.service [Service] ExecStart=/usr/share/pve-manager/helpers/pve-sdn-commit -- 2.47.3