netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH nf-next 0/3] Control nf flow table timeouts
@ 2021-06-03 12:12 Oz Shlomo
  2021-06-03 12:12 ` [PATCH nf-next 1/3] netfilter: conntrack: Introduce tcp offload timeout configuration Oz Shlomo
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Oz Shlomo @ 2021-06-03 12:12 UTC (permalink / raw)
  To: Pablo Neira Ayuso; +Cc: Paul Blakey, netfilter-devel, Saeed Mahameed, Oz Shlomo

TCP and UDP connections may be offloaded from nf conntrack to nf flow table.
Offloaded connections are aged after 30 seconds of inactivity. 
Once aged, ownership is returned to conntrack with a hard coded tcp/udp
pickup time of 120/30 seconds, after which the connection may be deleted. 

The current hard-coded pickup intervals may introduce a very aggressive
aging policy. For example, offloaded tcp connections in established state
will timeout from nf conntrack after just 150 seconds of inactivity, 
instead of 5 days. In addition, the hard-coded 30 second offload timeout
period can significantly increase the hardware insertion rate requirements
in some use cases.

This patchset provides the user with the ability to configure protocol
specific offload timeout and pickup intervals via sysctl.
The first and second patches introduce the sysctl configuration for
tcp and udp protocols. The last patch modifies nf flow table aging
mechanisms to use the configured time intervals.

Oz Shlomo (3):
  netfilter: conntrack: Introduce tcp offload timeout configuration
  netfilter: conntrack: Introduce udp offload timeout configuration
  netfilter: flowtable: Set offload timeouts according to proto values

 include/net/netfilter/nf_flow_table.h   |  2 ++
 include/net/netns/conntrack.h           |  8 ++++++
 net/netfilter/nf_conntrack_proto_tcp.c  |  5 ++++
 net/netfilter/nf_conntrack_proto_udp.c  |  5 ++++
 net/netfilter/nf_conntrack_standalone.c | 46 ++++++++++++++++++++++++++++++++
 net/netfilter/nf_flow_table_core.c      | 47 ++++++++++++++++++++++++++-------
 net/netfilter/nf_flow_table_offload.c   |  4 +--
 7 files changed, 105 insertions(+), 12 deletions(-)

-- 
1.8.3.1


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

end of thread, other threads:[~2021-06-10  7:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-03 12:12 [PATCH nf-next 0/3] Control nf flow table timeouts Oz Shlomo
2021-06-03 12:12 ` [PATCH nf-next 1/3] netfilter: conntrack: Introduce tcp offload timeout configuration Oz Shlomo
2021-06-03 12:12 ` [PATCH nf-next 2/3] netfilter: conntrack: Introduce udp " Oz Shlomo
2021-06-03 12:12 ` [PATCH nf-next 3/3] netfilter: flowtable: Set offload timeouts according to proto values Oz Shlomo
2021-06-07 12:16 ` [PATCH nf-next 0/3] Control nf flow table timeouts Pablo Neira Ayuso
2021-06-09 23:12   ` Marcelo Ricardo Leitner
2021-06-10  7:08     ` Oz Shlomo

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).