摘要
随着网络快速发展,业务越发复杂,RSS和对称RSS分流不均衡导致高性能数据包处理框架DPDK性能不能充分发挥,针对这一问题提出了一种双hash负载均衡算法。该算法通过网卡硬件特性对称RSS机制和软件实现的对称hash算法,对数据包五元组信息进行哈希散列确定对应的逻辑核实现均衡分流。搭建了实验测试环境,和对称RSS算法对比,实验结果表明对称RSS算法分流不均衡,10次实验结果的CPU使用率的均方差为334.48。而双hash负载均衡算法分流均衡,各个逻辑核的CPU使用率均控制在50%范围小幅波动,对于10次实验结果的CPU使用率的均方差仅为23.92,达到了较好的均衡效果。提出的双hash均衡算法对于基于DPDK的网络处理设备研制具有一定参考价值。
This paper proposes a dual-hash load balancing algorithm.The algorithm uses the symmetric RSS mechanism of the hardware characteristics of the network card and the symmetric hash algorithm implemented by software to hash the quintuple information of the data packet to determine the corresponding logical core to achieve balanced distribution.An experimental test environment is built,and compared with the symmetric RSS algorithm,the experimental results show that the symmetric RSS algorithm is not balanced,and the mean square error of the CPU usage of 10 experimental results is 334.48.In the dual-hash load balancing algorithm,the CPU usage of each logical core is controlled within 50%and fluctuates slightly.The mean square error of the CPU usage of the 10 experimental results is only 23.92,achieving a good balancing effect.
出处
《工业控制计算机》
2023年第1期65-67,70,共4页
Industrial Control Computer