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 7CD781FF0C0 for ; Wed, 18 Nov 2026 15:13:08 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id DB76621669; Wed, 18 Nov 2026 15:13:06 +0100 (CET) Message-ID: <50a15a4d-a6f5-49df-92dc-21534d83fdb3@proxmox.com> Date: Wed, 18 Nov 2026 15:13:00 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH pve-common v3 01/32] interfaces: preserve VRF membership across address family changes To: pve-devel@lists.proxmox.com References: <20261116161154.343743-1-g.goller@proxmox.com> <20261116161154.343743-2-g.goller@proxmox.com> Content-Language: en-US From: Stefan Hanreich In-Reply-To: <20261116161154.343743-2-g.goller@proxmox.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.224 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: JSJODRHGL4TGD5BGWZPIXZHHVF7EYTFI X-Message-ID-Hash: JSJODRHGL4TGD5BGWZPIXZHHVF7EYTFI X-MailFrom: s.hanreich@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: Can we additionally deny VRF for all OVS types for now? We should also check if an interface is part of a fabric? On 11/16/26 5:12 PM, Gabriel Goller wrote: > Store VRF membership as an interface option, not an address family > option. Otherwise, switching from IPv4 to IPv6-only can drop the VRF > assignment when the IPv4 stanza is removed. > > Signed-off-by: Gabriel Goller > --- > src/PVE/Network/Interfaces.pm | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/src/PVE/Network/Interfaces.pm b/src/PVE/Network/Interfaces.pm > index 8aed1ab3c473..bfaab278d556 100644 > --- a/src/PVE/Network/Interfaces.pm > +++ b/src/PVE/Network/Interfaces.pm > @@ -134,7 +134,7 @@ my $check_mtu = sub($ifaces, $parent, $child) { > # gateway6 => IP, > # comments6 => [ "..." ], > # > -# , # like bridge_ports, ovs_* > +# , # interface-wide (shared by inet/inet6): bridge_ports, ovs_*, vrf > # > # # extra/unknown options stored by-family: > # options => { ... } > @@ -226,6 +226,7 @@ sub __read_etc_network_interfaces($fh, $ip_links = undef, $active_ifaces = undef > > my $simple_options = { > 'mtu' => 1, > + 'vrf' => 1, > 'ovs_type' => 1, > 'ovs_options' => 1, > 'ovs_bridge' => 1, > @@ -904,6 +905,7 @@ sub __write_etc_network_interfaces($config, $ifupdown2 = undef) { > $n->{autostart} = 1; > > die "bond '$iface' - unable to find slave '$p'\n" if !$n; > + die "bond '$iface' - slave '$p' cannot have a VRF master\n" if $n->{vrf}; > die > "bond '$iface' - wrong interface type on slave '$p' ('$n->{type}' != 'eth or bond')\n" > if ($n->{type} ne 'eth' && $n->{type} ne 'bond'); > @@ -1027,6 +1029,7 @@ sub __write_etc_network_interfaces($config, $ifupdown2 = undef) { > } > my $n = $ifaces_copy->{$p}; > die "bridge '$iface' - unable to find bridge port '$p'\n" if !$n; > + die "bridge '$iface' - port '$p' cannot have a VRF master\n" if $n->{vrf}; > die "iface $p - ip address can't be set on interface if bridged in $iface\n" > if ($n->{method} && $n->{method} eq 'static' && $n->{address} ne '0.0.0.0') > || ($n->{method6} && $n->{method6} eq 'static' && $n->{address6} ne '::');