liunx双网卡绑定
root@node201 /etc/sysconfig/network-scripts]# cat ifcfg-bond0
TYPE=Ethernet
BOOTPROTO=static
DEVICE=bond0
ONBOOT=yes
IPADDR=172.30.1.201
NETMASK=255.255.255.0
GATEWAY=172.30.1.254
DNS1=172.30.1.254
BONDING_OPTS="miimon=100 mode=1" //mode=0 表示双网卡负载,mode=1,表示主备冗余
[root@node201 /etc/sysconfig/network-scripts]# cat ifcfg-ens33
TYPE=Ethernet
BOOTPROTO=none
DEVICE=ens33
ONBOOT=yes
MASTER=bond0
SLAVE=yes
[root@node201 /etc/sysconfig/network-scripts]# cat ifcfg-ens34
TYPE=Ethernet
BOOTPROTO=none
DEVICE=ens34
ONBOOT=yes
MASTER=bond0
SLAVE=yes
[root@node201 /etc/sysconfig/network-scripts]#