在Windows下面配置复杂的多网卡负载均衡在Linux下面无比简单。
首先是安装ifenslave,这个在Ubuntu下面就一指令:
sudo apt-get install ifenslave
然后修改/etc/modprobe.d/arch/
加入以下内容:
alias bond0 bonding
options bond0 mode=balance-alb miimon=100 max_bonds=2
最后修改/etc/network/interfaces,把原来的eth0,eth1配置注释掉,加入下面的内容:
auto bond0
iface bond0 inet static
address 192.168.1.3
netmask 255.255.255.0
gateway 192.168.1.1
up /sbin/ifenslave bond0 eth0 eth1
down /sbin/ifenslave -d bond0 eht0 eth1
OK,重启一下,让网卡负载均衡功能启用。就这么简单了。