netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] selftests: forwarding: mirror_gre_nh: Unset rp_filter on host VRF
@ 2018-07-10 12:44 Petr Machata
  2018-07-12  6:59 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Petr Machata @ 2018-07-10 12:44 UTC (permalink / raw)
  To: netdev, linux-kselftest; +Cc: davem, shuah, idosch

The mirrored packets arrive at $h3 encapsulated in GRE/IPv4, with IP
address from 192.0.2.128/28 network. However the interface is configured
as a member of 192.0.2.160/28 and there's no route directing traffic
from the former network through that interface. Correspondingly, the RP
filter on the VRF rejects it.

Therefore turn off the VRF's RP filter.

Signed-off-by: Petr Machata <petrm@mellanox.com>
---
 tools/testing/selftests/net/forwarding/mirror_gre_nh.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh b/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
index 8fa681eb90e7..6f9ef1820e93 100755
--- a/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
+++ b/tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
@@ -35,6 +35,8 @@ setup_prepare()
 	vrf_prepare
 	mirror_gre_topo_create
 
+	sysctl_set net.ipv4.conf.v$h3.rp_filter 0
+
 	ip address add dev $swp3 192.0.2.161/28
 	ip address add dev $h3 192.0.2.162/28
 	ip address add dev gt4 192.0.2.129/32
@@ -61,6 +63,8 @@ cleanup()
 	ip address del dev $h3 192.0.2.162/28
 	ip address del dev $swp3 192.0.2.161/28
 
+	sysctl_restore net.ipv4.conf.v$h3.rp_filter 0
+
 	mirror_gre_topo_destroy
 	vrf_cleanup
 
-- 
2.4.11

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] selftests: forwarding: mirror_gre_nh: Unset rp_filter on host VRF
  2018-07-10 12:44 [PATCH net-next] selftests: forwarding: mirror_gre_nh: Unset rp_filter on host VRF Petr Machata
@ 2018-07-12  6:59 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2018-07-12  6:59 UTC (permalink / raw)
  To: petrm; +Cc: netdev, linux-kselftest, shuah, idosch

From: Petr Machata <petrm@mellanox.com>
Date: Tue, 10 Jul 2018 14:44:26 +0200

> The mirrored packets arrive at $h3 encapsulated in GRE/IPv4, with IP
> address from 192.0.2.128/28 network. However the interface is configured
> as a member of 192.0.2.160/28 and there's no route directing traffic
> from the former network through that interface. Correspondingly, the RP
> filter on the VRF rejects it.
> 
> Therefore turn off the VRF's RP filter.
> 
> Signed-off-by: Petr Machata <petrm@mellanox.com>

Applied.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-07-12  7:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-10 12:44 [PATCH net-next] selftests: forwarding: mirror_gre_nh: Unset rp_filter on host VRF Petr Machata
2018-07-12  6:59 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).