From owner-freebsd-net@freebsd.org Fri Jan 22 13:26:15 2021 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7CAA44F54E4 for ; Fri, 22 Jan 2021 13:26:15 +0000 (UTC) (envelope-from vit@otcnet.ru) Received: from mail.otcnet.ru (mail.otcnet.ru [194.190.78.3]) by mx1.freebsd.org (Postfix) with ESMTP id 4DMg525n7Nz3C49 for ; Fri, 22 Jan 2021 13:26:14 +0000 (UTC) (envelope-from vit@otcnet.ru) Received: from VitComp.local (unknown [195.91.218.161]) by mail.otcnet.ru (Postfix) with ESMTPSA id 18D256224E; Fri, 22 Jan 2021 16:26:14 +0300 (MSK) Subject: Re: 'dropped due to full socket buffers' by SNMP To: Eugene Grosbein , freebsd-net@freebsd.org References: <388da9a7-7b89-89b2-54eb-17d0e818c924@otcnet.ru> <4e41c1d2-19bc-0345-0b03-526e4cb785c7@otcnet.ru> <6c780827-e764-8053-356b-a921e0892c15@grosbein.net> <7e51a6be-aea1-51c6-c0bd-10d00c19d5d3@grosbein.net> <888c8e91-c8f2-ad4b-9fcf-64c09432f2d5@otcnet.ru> <427b5ef6-9558-22ad-6088-c852bf234d13@otcnet.ru> <706bf341-01dd-f9f9-a5a8-afb8c34d5572@grosbein.net> <226279d6-7579-9441-9854-f238057abeb6@otcnet.ru> <8c80810d-b244-4bbc-d14c-0ca37348b5a5@grosbein.net> From: Victor Gamov Message-ID: Date: Fri, 22 Jan 2021 16:26:10 +0300 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 MIME-Version: 1.0 In-Reply-To: <8c80810d-b244-4bbc-d14c-0ca37348b5a5@grosbein.net> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: ru Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4DMg525n7Nz3C49 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of vit@otcnet.ru designates 194.190.78.3 as permitted sender) smtp.mailfrom=vit@otcnet.ru X-Spamd-Result: default: False [-2.92 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+a:mail.otcnet.ru]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[otcnet.ru]; RBL_DBL_DONT_QUERY_IPS(0.00)[194.190.78.3:from]; SPAMHAUS_ZRD(0.00)[194.190.78.3:from:127.0.2.255]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.72)[-0.715]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:50822, ipnet:194.190.78.0/24, country:RU]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-net] X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Jan 2021 13:26:15 -0000 On 22.01.2021 16:09, Eugene Grosbein wrote: > 22.01.2021 19:28, Victor Gamov wrote: > >> On 22.01.2021 13:21, Eugene Grosbein wrote: >>> 22.01.2021 17:02, Victor Gamov wrote: >>> >>>> No link overload: this host attached to network via 10G ix0, many >>>> VLANs on this ix0 and some sender on every VLAN sends multicast >>>> traffic to this host. Total input traffic about 1Gbit/s >>> >>> What FreeBSD version do you use currently? Do you use IPv6 for UDP or >>> IPv4 only? >> >> >> FreeBSD 12.2-STABLE r366543 GENERIC amd64 >> >> UDP-4 only > > In case of IPv4 UDP the counter "dropped due to full socket buffers" > is increased for incoming packets only. Therefore, the problem is in a code > processing incoming stream(s): either it locks for long time on something, > or it just has no enough raw CPU horsepower to deal with incoming stream. > > Look at "top -SHPI" CPU counters, if your CPU cores are loaded evenly; it's CPU E3-1270 v6 @ 3.80GHz with WCPU about 60% idle + 9% kernel{if_io_tqg_X) + 5% intr{swi1: netisr X). And many processes about 1% WCPU for multicast receive/resend (one for every multicast) Also "netstat -na -p udp" shows me zero or very small Recv-Q > if some of cores became overloaded sometimes. You should also draw per-cpu load graphs. > (f.e. sysctl kern.cp_times) I have SNMP stats and it show me about 40% load I have no visible problems with growing "dropped due to full socket buffers" but I think it's not well when this counter increasing. -- CU, Victor Gamov