From: Sriram Yagnaraman <sriram.yagnaraman@est.tech>
Cc: netdev@vger.kernel.org, linux-kselftest@vger.kernel.org,
"David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
David Ahern <dsahern@kernel.org>,
Ido Schimmel <idosch@nvidia.com>, Shuah Khan <shuah@kernel.org>,
Sriram Yagnaraman <sriram.yagnaraman@est.tech>
Subject: [PATCH 0/3] Avoid TCP resets when using ECMP for load-balancing between multiple servers.
Date: Sat, 19 Aug 2023 13:48:22 +0200 [thread overview]
Message-ID: <20230819114825.30867-1-sriram.yagnaraman@est.tech> (raw)
All packets in the same flow (L3/L4 depending on multipath hash policy)
should be directed to the same target, but after [0]/[1] we see stray
packets directed towards other targets. This, for instance, causes RST
to be sent on TCP connections.
The first two patches solve the problem by ignoring route hints for
destinations that are part of multipath group, by using new SKB flags
for IPv4 and IPv6. The third patch is a selftest that tests the
scenario.
Thanks to Ido, for reviewing and suggesting a way forward in [2].
[0]: commit 02b24941619f ("ipv4: use dst hint for ipv4 list receive")
[1]: commit 197dbf24e360
("ipv6: introduce and uses route look hints for list input.")
[2]: https://lore.kernel.org/netdev/20230815201048.1796-1-sriram.yagnaraman@est.tech/
Sriram Yagnaraman (3):
ipv4: ignore dst hint for multipath routes
ipv6: ignore dst hint for multipath routes
selftests: forwarding: Add test for load-balancing between multiple
servers
include/linux/ipv6.h | 1 +
include/net/ip.h | 1 +
net/ipv4/ip_input.c | 3 +-
net/ipv4/route.c | 1 +
net/ipv6/ip6_input.c | 3 +-
net/ipv6/route.c | 2 +
.../testing/selftests/net/forwarding/Makefile | 1 +
.../net/forwarding/router_multipath_vip.sh | 403 ++++++++++++++++++
8 files changed, 413 insertions(+), 2 deletions(-)
create mode 100755 tools/testing/selftests/net/forwarding/router_multipath_vip.sh
--
2.34.1
next reply other threads:[~2023-08-19 11:50 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-19 11:48 Sriram Yagnaraman [this message]
2023-08-19 11:48 ` [PATCH 1/3] ipv4: ignore dst hint for multipath routes Sriram Yagnaraman
2023-08-21 11:39 ` Ido Schimmel
2023-08-19 11:48 ` [PATCH 2/3] ipv6: " Sriram Yagnaraman
2023-08-19 11:48 ` [PATCH 3/3] selftests: forwarding: Add test for load-balancing between multiple servers Sriram Yagnaraman
2023-08-21 11:34 ` Ido Schimmel
2023-08-21 19:36 ` Sriram Yagnaraman
2023-08-22 18:57 ` Ido Schimmel
2023-08-23 12:55 ` Sriram Yagnaraman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230819114825.30867-1-sriram.yagnaraman@est.tech \
--to=sriram.yagnaraman@est.tech \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=idosch@nvidia.com \
--cc=kuba@kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).