Commit e8658023 authored by Guillaume Nault's avatar Guillaume Nault Committed by Jakub Kicinski

selftests: set conf.all.rp_filter=0 in bareudp.sh

When working on the rp_filter problem, I didn't realise that disabling
it on the network devices didn't cover all cases: rp_filter could also
be enabled globally in the namespace, in which case it would drop
packets, even if the net device has rp_filter=0.

Fixes: 1ccd5833 ("selftests: disable rp_filter when testing bareudp")
Fixes: bbbc7aa4 ("selftests: add test script for bareudp tunnels")
Signed-off-by: default avatarGuillaume Nault <gnault@redhat.com>
Link: https://lore.kernel.org/r/f2d459346471f163b239aa9d63ce3e2ba9c62895.1605107012.git.gnault@redhat.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent e7086213
......@@ -238,6 +238,8 @@ setup_overlay_ipv4()
# The intermediate namespaces don't have routes for the reverse path,
# as it will be handled by tc. So we need to ensure that rp_filter is
# not going to block the traffic.
ip netns exec "${NS1}" sysctl -qw net.ipv4.conf.all.rp_filter=0
ip netns exec "${NS2}" sysctl -qw net.ipv4.conf.all.rp_filter=0
ip netns exec "${NS1}" sysctl -qw net.ipv4.conf.default.rp_filter=0
ip netns exec "${NS2}" sysctl -qw net.ipv4.conf.default.rp_filter=0
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment