From: David Miller <davem@davemloft.net>
To: roman.kapl@sysgo.com
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] net: set default value for somaxconn
Date: Mon, 22 May 2017 14:18:09 -0400 (EDT) [thread overview]
Message-ID: <20170522.141809.2056075174395561778.davem@davemloft.net> (raw)
In-Reply-To: <20170522122241.28389-1-roman.kapl@sysgo.com>
From: Roman Kapl <roman.kapl@sysgo.com>
Date: Mon, 22 May 2017 14:22:41 +0200
> The default value for somaxconn is set in sysctl_core_net_init(), but this
> function is not called when kernel is configured without CONFIG_SYSCTL.
>
> This results in the kernel not being able to accept TCP connections,
> because the backlog has zero size. Usually, the user ends up with:
> "TCP: request_sock_TCP: Possible SYN flooding on port 7. Dropping request. Check SNMP counters."
>
> Before ef547f2ac16 (tcp: remove max_qlen_log), the effects were less
> severe, because the backlog was always at least eight slots long.
>
> Signed-off-by: Roman Kapl <roman.kapl@sysgo.com>
I see the problem, but this changes behavior.
Existing code will set somaxconn to the default value for every namespace
that is created.
But with you changes, any modification made to init_net's value will
get inherited by any namespace created as a child thereafterwards.
You really need to make this happen via pernet_operations, or even
inside of setup_net().
next prev parent reply other threads:[~2017-05-22 18:18 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-22 12:22 [PATCH] net: set default value for somaxconn Roman Kapl
2017-05-22 18:18 ` David Miller [this message]
2017-05-23 12:26 ` Roman Kapl
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=20170522.141809.2056075174395561778.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=roman.kapl@sysgo.com \
/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).