From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 3865D941A7 for ; Wed, 21 Feb 2024 15:14:52 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 17243190DC for ; Wed, 21 Feb 2024 15:14:22 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Wed, 21 Feb 2024 15:14:21 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 29B6544533; Wed, 21 Feb 2024 15:14:21 +0100 (CET) Message-ID: Date: Wed, 21 Feb 2024 15:14:20 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Proxmox VE development discussion , Jillian Morgan References: <20240126171741.2251760-1-jillian.morgan@primordial.ca> <20240126171741.2251760-3-jillian.morgan@primordial.ca> From: Stefan Hanreich In-Reply-To: <20240126171741.2251760-3-jillian.morgan@primordial.ca> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.501 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 T_SCC_BODY_TEXT_LINE -0.01 - Subject: Re: [pve-devel] [PATCH close #545, #5203: Allow bridges to have any valid interface name 2/2] 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: , X-List-Received-Date: Wed, 21 Feb 2024 14:14:52 -0000 On 1/26/24 18:17, Jillian Morgan wrote: > Detect bridge interface by bridge_ports attribute > Repo: pve-common > > Similar to other interface types, we can detect a bridge by the presense of > it's bridge_ports attribute rather than solely relying on the "vmbr" ifname > prefix heuristic. > > Signed-off-by: Jillian Morgan > --- > pve-common/src/PVE/INotify.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/PVE/INotify.pm b/src/PVE/INotify.pm > index 6432295..9b45346 100644 > --- a/src/PVE/INotify.pm > +++ b/src/PVE/INotify.pm > @@ -1053,7 +1053,7 @@ sub __read_etc_network_interfaces { > my $tag = &$extract_ovs_option($d, 'tag'); > $d->{ovs_tag} = $tag if defined($tag); > } > - } elsif ($iface =~ m/^vmbr\d+$/) { > + } elsif ($iface =~ m/^vmbr\d+$/ || $d->{'bridge_ports'}) { This only works for detecting Linux bridges, we would need to add an additional check for OVS bridges as well > if (!$d->{ovs_type}) { > $d->{type} = 'bridge'; > if (!defined ($d->{bridge_stp})) { > > _______________________________________________ > pve-devel mailing list > pve-devel@lists.proxmox.com > https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel > >