编辑eth0

DEVICE=eth0

TYPE=Ethernet
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOTTPROTO=none

编辑eth1

DEVICE=eth1
ONBOOT=yes
MASTER=bond0
SLAVE=yes
BOTTPROTO=none

编辑bond0

DEVICE=bond0

BOOTPROTO=static
IPADDR=10.10.128.13
NETMASK=255.255.192.0
GATEWAY=10.10.128.254
ONBOOT=YES
USERCTL=no
添加模块:

[root@foldg network-scripts]# cat /etc/modprobe.d/bonding.conf

alias  bond0 bonding
options bonding miimon=100  mode=1

加载模块:

[root@foldg network-scripts]# modprobe bonding

查看网卡模式:

[root@foldg proc]# cat /proc/net/bonding/bond0

Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)

Bonding Mode: fault-tolerance (active-backup)

Primary Slave: None
Currently Active Slave: eth1
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 0
Down Delay (ms): 0

Slave Interface: eth0

MII Status: up
Speed: 1000 Mbps
Duplex: full
Link Failure Count: 1
Permanent HW addr: 40:f2:e9:b9:ab:68
Slave queue ID: 0

Slave Interface: eth1

MII Status: up
Speed: 1000 Mbps
Duplex: full
Link Failure Count: 0
Permanent HW addr: 40:f2:e9:b9:ab:69
Slave queue ID: 0