Subject: Re: UDP packet loss when running lsof

From: Eric Dumazet <[email-masked]>
Date: Tue, 22 May 2007 08:47:40 +0200

Eric Dumazet a écrit :
> John Miller a écrit :
>> Hi Eric,
>>
>>> I CCed netdev since this stuff is about network and not
>>> lkml.
>>
>> Ok, dropped the CC...
>>
>>> What kind of machine do you have ? SMP or not ?
>>
>> It's a HP system with two dual core CPUs at 3GHz, the
>> storage system is connected through QLogic FC-HBA. It should
>> really be fast enough to handle a data stream of 50 MB/s...
> 
> Then you might try to bind network IRQ to one CPU
> (echo 1 >/proc/irq/XX/smp_affinity)
> 
> XX being your NIC interrupt (cat /proc/interrupts to catch it)
> 
> and bind your user program to another cpu(s)
> 
> You might hit a cond_resched_softirq() bug that Ingo and others are 
> sorting out right now. Using separate CPU for softirq handling and your 
> programs should help a lot here.

You might try this patch, now that Ingo "Signed-off-by" it.

http://marc.info/?l=linux-kernel&m=117981607429875&w=2

I guess that with a correct softirq resched, no need to play with IRQ 
affinities, unless you really want to push performance.