安装和使用
本文档以基于“Docker+Bond4+IPVLAN”的组网环境进行优化。安装和使用该特性之前,请确保已完成相应组网环境的搭建。
- 执行以下命令进行环境基线配置。
1 2 3 4 5 6 7 8
systemctl stop firewalld.service systemctl disable firewalld.service sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/sysconfig/selinux setenforce 0 systemctl stop irqbalance.service systemctl disable irqbalance.service swapoff -a systemctl start irqbalance
以下三条命令分开执行。
1sed -i "s/CleanupModulesOnExit=no/CleanupModulesOnExit=yes/g" /etc/firewalld/*.conf
1systemctl restart firewalld
1systemctl stop firewalld
 - 关闭irqbalance。
1systemctl stop irqbalance
 - 网络多路径模块依赖hisi_l3t.ko,需要确认该模块是否已加载。
1lsmod | grep hisi_l3t
若上述命令输出为空,则需要加载hisi_l3t.ko。1modprobe hisi_l3t - 配置网卡信息,启用网络多路径特性。
1modprobe oenetcls ifname="Eth1#Eth2" mode=1
 - Eth1和Eth2需要根据实际情况配置成Server端配置使用的两张网卡的设备名称。
 - 使能网络多路径特性后,网卡中断会根据队列数均匀绑定到每个NUMA Node的前n个CPU上。
 - 若网络未组Bond4,则启用网络多路径的命令为modprobe oenetcls ifname="Eth1" mode=1
 
 - 通过Sysbench进行测试,详细测试步骤请参见《MySQL数据库Sysbench 测试指导》。
 
父主题: MySQL网络多路径优化特性指南