本文主要是介绍减少网卡中断收包产生的CPU消耗,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
目标:减少网卡中断收包产生的CPU消耗。
优化的措施:
1, 减少收包的队列数:igb.RSS
2, 减少中断调用的次数:rx-usecs
Some useful tips:
1, IGB driver requires the following parameter
igb.RSS
which demonstrates the number of Receive-Side Scaling (RSS)descriptor queues,in the case, it reduces from 8 to 5 which means enable 5 queues。
2, rx-usecs
The parameterto modify are called interrupt coalescing parameters, It is the number of usecs to wait beforeraising an RX interrupt after a packet has been received, when rx-usesc is setto 0 rx-frames is used.
You may wish toreduce rx-usecs if latency is more important and you are using a low-latencyswitch or a point-to-point connection. Similarly, you may wish to increaserx-usecs if you are interested in reducing CPU overhead for large transfers.Note that rx-usecs controls both transmit and receive coalescing, In the
这篇关于减少网卡中断收包产生的CPU消耗的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!