From be147e1ae3aa957b09f8ecb20c8ae3c5d6d9826c Mon Sep 17 00:00:00 2001 From: Donald Buczek Date: Fri, 22 Sep 2023 12:25:15 +0200 Subject: [PATCH] mxrouterctl: Fix bug with inherited vlan interfaces Currently, when a vlan interface is created on the host system (e.g. with mxvlan) and moved to the mxrouter instance with interface(), it gets deleted, because it is recogized visible as a vlan interface in the router namespace but not configured via vlan(). Ignore existing vlan interfaces which are configured into the router namespace via interface(). --- mxrouter/mxrouterctl | 1 + 1 file changed, 1 insertion(+) diff --git a/mxrouter/mxrouterctl b/mxrouter/mxrouterctl index b8fb6ed..457241a 100755 --- a/mxrouter/mxrouterctl +++ b/mxrouter/mxrouterctl @@ -488,6 +488,7 @@ sub start { } my ($have_vlan)=read_active_vlans(); + delete $have_vlan->{$_} for keys %$want_if; # vlan interfaces created in main and moved via interaface() my ($new_vlan,$del_vlan)=({},{},{},{}); for (keys %$want_vlan) {