[pve-devel] [PATCH pve-manager 1/3] ifupdown1: bridgevlan: add bridge-vids list support

Alexandre DERUMIER aderumier at odiso.com
Thu Jan 9 12:17:13 CET 2020


>>       Before christmas i was testing the VLAN aware bridge functionality and
>>I found the hard way that mlx4 based network cards don't support more
>>than 128 VLAN's at the same time, or at least not with the default
>>configuration. 
Hi, yes, I'm aware of this, I had mellanox connectx3 card, and I had this problem since kernel 4.15.


>>I think that instead of adding ranges, the VID's should
>>be added dynamically when a VM starts and it should check for fails too
>>or else you could end up with a non working network card in the VM and
>>no indication of the fail.

The problem is that proxmox can't known exactly how much vlan can support a specific card.
so if you had dynamically vlan, you could have the bug when more than 128 is dynamicly added,
so it could break your proxmox host live when a vm will be started.

so, adding the vlan in /etc/network/interfaces is more safe.
(BTW, if ifupdown2 package, you can now reload network config online)




----- Mail original -----
De: "Jorge Boncompte" <jbonor at gmail.com>
À: "pve-devel" <pve-devel at pve.proxmox.com>
Envoyé: Mercredi 8 Janvier 2020 19:15:25
Objet: Re: [pve-devel] [PATCH pve-manager 1/3] ifupdown1: bridgevlan: add bridge-vids list support

El 8/1/20 a las 4:31, Alexandre Derumier escribió: 
> like ifupdown2, support multiple values 
> 
> iface vmbr0 
> bridge-vids 2 4 5-10 70 

Before christmas i was testing the VLAN aware bridge functionality and 
I found the hard way that mlx4 based network cards don't support more 
than 128 VLAN's at the same time, or at least not with the default 
configuration. I think that instead of adding ranges, the VID's should 
be added dynamically when a VM starts and it should check for fails too 
or else you could end up with a non working network card in the VM and 
no indication of the fail. 

Best regards. 

> 
> Signed-off-by: Alexandre Derumier <aderumier at odiso.com> 
> --- 
> network-hooks/bridgevlan | 5 ++++- 
> 1 file changed, 4 insertions(+), 1 deletion(-) 
> 
> diff --git a/network-hooks/bridgevlan b/network-hooks/bridgevlan 
> index ea043575..3965bfda 100755 
> --- a/network-hooks/bridgevlan 
> +++ b/network-hooks/bridgevlan 
> @@ -41,7 +41,10 @@ do 
> # we allow vlan to pass through attached interface 
> if [ -n "$IF_BRIDGE_VIDS" ] 
> then 
> - bridge vlan add dev $port vid $IF_BRIDGE_VIDS 
> + for VID in $IF_BRIDGE_VIDS 
> + do 
> + bridge vlan add dev $port vid $VID 
> + done 
> else 
> bridge vlan add dev $port vid 2-4094 
> fi 
> 

_______________________________________________ 
pve-devel mailing list 
pve-devel at pve.proxmox.com 
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel 




More information about the pve-devel mailing list