From owner-freebsd-net@FreeBSD.ORG Tue Jan 18 17:20:11 2011 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D72B106564A for ; Tue, 18 Jan 2011 17:20:11 +0000 (UTC) (envelope-from mike@sentex.net) Received: from smarthost1.sentex.ca (smarthost1-6.sentex.ca [IPv6:2607:f3e0:0:1::12]) by mx1.freebsd.org (Postfix) with ESMTP id CBB218FC1B for ; Tue, 18 Jan 2011 17:20:10 +0000 (UTC) Received: from [IPv6:2607:f3e0:0:4:f025:8813:7603:7e4a] (saphire3.sentex.ca [IPv6:2607:f3e0:0:4:f025:8813:7603:7e4a]) by smarthost1.sentex.ca (8.14.4/8.14.4) with ESMTP id p0IHK84l091262 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Tue, 18 Jan 2011 12:20:08 -0500 (EST) (envelope-from mike@sentex.net) Message-ID: <4D35CBCB.1040001@sentex.net> Date: Tue, 18 Jan 2011 12:20:11 -0500 From: Mike Tancsa User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Eugene Grosbein References: <4D3011DB.9050900@frasunek.com> <4D30458D.30007@sentex.net> <4D341E80.7000303@rdtc.ru> <4D342AEC.4030600@sentex.net> <4D346AEB.8000807@rdtc.ru> In-Reply-To: <4D346AEB.8000807@rdtc.ru> X-Enigmail-Version: 1.1.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on IPv6:2607:f3e0:0:1::12 Cc: freebsd-net@freebsd.org Subject: Re: Netgraph/mpd5 stability issues X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Jan 2011 17:20:11 -0000 On 1/17/2011 11:14 AM, Eugene Grosbein wrote: > On 17.01.2011 17:41, Mike Tancsa wrote: > >>>> I also have stability issues on RELENG_8. >>>> >>>> http://www.freebsd.org/cgi/query-pr.cgi?pr=153497 >>> >>> Do you change net.isr.direct from default 1 to 0 for your box? >> >> No, I leave it at 1 >> >> ---Mike > > I was experiencing some instability with mpd/netgraph too > but found workaround: increase netgraph buffers/queues. > > For 4GB RAM, /boot/loader.conf: > > # netgraph queue sizes tuning, see vmstat -z|egrep 'ITEM|NetGraph' > net.graph.maxdata=65536 > net.graph.maxalloc=65536 > > For /etc/sysctl.conf: > > kern.ipc.maxsockbuf=83886080 > net.graph.maxdgram=8388608 > net.graph.recvspace=8388608 > > It helps not to overflow netgraph event queues in my case > and takes away netgraph-related stability problems. I have only 2G of RAM on i386. On a box that has ipv6 disabled, with 641 ng interfaces right now # vmstat -z | egrep -i 'item|netg' ITEM SIZE LIMIT USED FREE REQUESTS FAILURES NetGraph items: 36, 4130, 2, 234, 8855752088, 0 NetGraph data items: 36, 531, 0, 472, 20152691765, 0 This is with 21 days of uptime and its quite stable. Enabling ipv6 seems to make the problems more likely for me. I had to restart it as the values I chose were too high and I was getting negative sbsize for uid = 0 vmstat -z | egrep -i 'ITEM|Netg' ITEM SIZE LIMIT USED FREE REQUESTS FAILURES NetGraph items: 36, 8201, 0, 236, 25397, 0 NetGraph data items: 36, 2065, 0, 236, 54671, 0 I tweaked things down net.graph.maxdata=2048 net.graph.maxalloc=8192 net.inet.ip.intr_queue_maxlen=500 kern.ipc.maxsockbuf=1048576 net.graph.maxdgram=524288 net.graph.recvspace=524288 I also have devd_enable="NO" ---Mike