Subject: Re: NetBSD and large pps
To: Mihai CHELARU <kefren@netbastards.org>
From: Mihai CHELARU <kefren@netbsd.ro>
List: tech-net
Date: 12/02/2004 20:44:49
Mihai CHELARU wrote:
> Martin Husemann wrote:
>
>> On Thu, Dec 02, 2004 at 12:13:04PM +0200, Mihai CHELARU wrote:
>>
>>> I don't use NAPI nics so I get around 30k irqs/sec. Is this a known
>>> issue ? What can I do about it ?
>>
>>
>>
>> What is NAPI?
>> What nics do you use?
>>
>> Martin
>>
>
> NAPI is also known as RX Polling. From what I understood it's a way of
> buffering ingress packets at layer 2 and not generating an IRQ for every
> packet it receives. It's available for Intel Pro/1000 (epro 1000).
>
> I use broadcom pci-x cards (bge) BCM5702X.
>
> For what I see there is a problem with IRQ limit in NetBSD. On other
> machine I have a pgsql that sometimes goes also at around 30k IRQs/sec
> and also suddenly reboots (don't ask me what that pgsql is doing there,
> some strange half-page select that is driving that multi-proc machine
> into nuts - 30k tlb shootdowns IRQs).
>
Btw, is it normal to act like this when it's bombarded with packets ?
root@smtp:~# cat check.c
#include <stdio.h>
#include <unistd.h>
#include <time.h>
main ()
{
int i=0;
for (;;i++) {
printf ("%d %d\n", i, time(NULL));
sleep(2);
}
}
root@smtp:~# make check
cc -O2 -o check check.c
root@smtp:~# ./check
0 1102012752
1 1102012754
2 1102012756
3 1102012758 <- Here I started to packet it
4 1102012761
5 1102012765
6 1102012769
7 1102012773
8 1102012777
9 1102012781
10 1102012787
11 1102012791
12 1102012795
13 1102012801
14 1102012805
15 1102012813
16 1102012817
17 1102012819
18 1102012821
19 1102012825
20 1102012831
21 1102012837
22 1102012841 <- And here I stop
23 1102012843
24 1102012845
25 1102012847
--
Thanks
Mihai