[pve-devel] [PATCH v2 firewall 6/6] simulator: use new bridge naming scheme

Thomas Lamprecht t.lamprecht at proxmox.com
Mon Feb 26 16:36:59 CET 2024


Am 26/02/2024 um 11:51 schrieb DERUMIER, Alexandre via pve-devel:
> hi,I think you should limit to 8 characters like for sdn vnet, 
> 
> as we need to space to  vlan tag for example (vmbrY.XXXX), or other sdn
> construct.

alternatively just show a hint in the UI if longer than 8 characters
and, if possible, error out with a clear message when one sets up
something that cannot work any more.

Not all users use those features, as long as they are made aware of
implications it can be fine to allow cases that do not allow every
possible feature.

That said, starting out with a 8 characters max length limit is quicker
to implement and would be fine for me.

Either using a common constant, or at least throw in a comment, and a
note in the commit message, with the reason for that limit, and that
it is shared between SDN vnets would be great though.

btw. one could also lift the strict naming scheme for bonds using
the 'bond-mode' flag to detect them.

Oh, and fwiw, having some awareness safety net like:

warn "..." if !defined $d->{'bridge_ports'} && $iface =~ m/^vmbr\d+$/;

for at least this major release could be nice to catch odd setups easier,
as IIRC that property really is required for ifupdown2 to consider an
interface as a bridge. Only this major release as then pve8to9 could
take over on warning for this and afterwards the admin either corrected
it or it's done by choice.




More information about the pve-devel mailing list