[PATCH net-next mlxsw] selftests: forwarding: mirror_gre_nh: Unset RP filter
Petr Machata
petrm at mellanox.com
Thu May 3 01:44:29 AEST 2018
The test fails to work if reverse-path filtering is in effect on the
mirrored-to host interface, or for all interfaces.
Signed-off-by: Petr Machata <petrm at mellanox.com>
---
tools/testing/selftests/net/forwarding/mirror_gre_nh.sh | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh b/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
index a0d1ad4..3575e9b 100755
--- a/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
+++ b/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
@@ -29,6 +29,11 @@ setup_prepare()
swp3=${NETIFS[p5]}
h3=${NETIFS[p6]}
+ all_rp_filter=$(sysctl -n net.ipv4.conf.all.rp_filter)
+ h3_rp_filter=$(sysctl -n net.ipv4.conf.$h3.rp_filter)
+ sysctl -qw net.ipv4.conf.all.rp_filter=0
+ sysctl -qw net.ipv4.conf.$h3.rp_filter=0
+
vrf_prepare
mirror_gre_topo_create
@@ -60,6 +65,9 @@ cleanup()
mirror_gre_topo_destroy
vrf_cleanup
+
+ sysctl -qw net.ipv4.conf.$h3.rp_filter=$h3_rp_filter
+ sysctl -qw net.ipv4.conf.all.rp_filter=$all_rp_filter
}
test_gretap()
--
2.4.11
More information about the Linux-mlxsw
mailing list