@@ -845,6 +845,7 @@ var _ = infrastructure.DatastoreDescribe("_BPF-SAFE_ VXLAN topology before addin
845
845
mtuStrV6 := "mtu 1430"
846
846
if BPFMode () {
847
847
mtuStr = "mtu 1500"
848
+ mtuStrV6 = "mtu 1500"
848
849
}
849
850
for _ , felix := range felixes {
850
851
Eventually (func () string {
@@ -867,23 +868,26 @@ var _ = infrastructure.DatastoreDescribe("_BPF-SAFE_ VXLAN topology before addin
867
868
_ , err := client .FelixConfigurations ().Create (context .Background (), felixConfig , options.SetOptions {})
868
869
Expect (err ).NotTo (HaveOccurred ())
869
870
870
- // Expect the ipv4 VXLAN device to be deleted.
871
- for _ , felix := range felixes {
872
- Eventually (func () string {
873
- out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan.calico" )
874
- return out
875
- }, "60s" , "500ms" ).ShouldNot (ContainSubstring (mtuStr ))
876
- // IPv6 ignores the VXLAN enabled flag and must be disabled at the pool level. As such the ipv6
877
- // interfaces should still exist at this point
878
- if ! BPFMode () && enableIPv6 {
871
+ if ! BPFMode () || ! enableIPv6 {
872
+ // Expect the ipv4 VXLAN device to be deleted. In BPFMode
873
+ // the same device is used for V6 as well
874
+ for _ , felix := range felixes {
879
875
Eventually (func () string {
880
- out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan-v6 .calico" )
876
+ out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan.calico" )
881
877
return out
882
- }, "60s" , "500ms" ).Should (ContainSubstring (mtuStrV6 ))
878
+ }, "60s" , "500ms" ).ShouldNot (ContainSubstring (mtuStr ))
879
+ // IPv6 ignores the VXLAN enabled flag and must be disabled at the pool level. As such the ipv6
880
+ // interfaces should still exist at this point
881
+ if enableIPv6 {
882
+ Eventually (func () string {
883
+ out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan-v6.calico" )
884
+ return out
885
+ }, "60s" , "500ms" ).Should (ContainSubstring (mtuStrV6 ))
886
+ }
883
887
}
884
888
}
885
889
886
- if ! BPFMode () && enableIPv6 {
890
+ if enableIPv6 {
887
891
ip6pool , err := client .IPPools ().Get (context .Background (), infrastructure .DefaultIPv6PoolName , options.GetOptions {})
888
892
Expect (err ).NotTo (HaveOccurred ())
889
893
ip6pool .Spec .VXLANMode = "Never"
@@ -893,6 +897,10 @@ var _ = infrastructure.DatastoreDescribe("_BPF-SAFE_ VXLAN topology before addin
893
897
// Expect the ipv6 VXLAN device to be deleted.
894
898
for _ , felix := range felixes {
895
899
Eventually (func () string {
900
+ if BPFMode () {
901
+ out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan.calico" )
902
+ return out
903
+ }
896
904
out , _ := felix .ExecOutput ("ip" , "-d" , "link" , "show" , "vxlan-v6.calico" )
897
905
return out
898
906
}, "60s" , "500ms" ).ShouldNot (ContainSubstring (mtuStrV6 ))
0 commit comments