Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Jan 2011 12:20:11 -0500
From:      Mike Tancsa <mike@sentex.net>
To:        Eugene Grosbein <egrosbein@rdtc.ru>
Cc:        freebsd-net@freebsd.org
Subject:   Re: Netgraph/mpd5 stability issues
Message-ID:  <4D35CBCB.1040001@sentex.net>
In-Reply-To: <4D346AEB.8000807@rdtc.ru>
References:  <4D3011DB.9050900@frasunek.com> <4D30458D.30007@sentex.net> <4D341E80.7000303@rdtc.ru> <4D342AEC.4030600@sentex.net> <4D346AEB.8000807@rdtc.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4D35CBCB.1040001>