Distribute IP packets accross different NIC queues with MSI (Message Signalled Interrupts)
Posted
by
Ansis Atteka
on Server Fault
See other posts from Server Fault
or by Ansis Atteka
Published on 2011-02-07T22:47:30Z
Indexed on
2011/02/07
23:27 UTC
Read the original article
Hit count: 535
NetXtreme II BCM5709 Gigabit Ethernet NIC supports MSI feature (Message Signaled Interrupts) and it has 8 queues. Each queue has its own Interrupt handler in /proc/interrupts. What I am trying to accomplish is to tell NIC which packets should go to which queue.
Questions:
- Is it possible to manually specify which IP packets should go to which queue by encapsulated protocol type (e.g. IPsec packets go in one queue, while TCP packets go in another queue)?
- If it is possible - how can I do it under Linux?
- If it is not possible - should I look at MSI-X capable NIC cards to solve this problem?
More details:
We have one Interface that is terminating IPSec and forwarding/terminating TCP connections. The IPSec packet decryption is inlined (this means that decryption is done under the same ksoftirqd/X context). We are trying to find out if we will be able to improve total performance if IPSec packets will be scheduled on another CPU than TCP packets. One more limitation is that IPSec code is not MP-safe, hence I can not run it under more than one ksoftirqd/X. By default it seems that packets are distributed/hashed by source IP over the 8 NIC queues. The bottleneck is IPSec that chokes out TCP traffic while it is decrypting/encrypting IPSec packets at ~100% CPU.
OS is Ubuntu 10.10 (2.6.32-27-server) and NIC is Broadcom BCM5709.
© Server Fault or respective owner