1,/etc/sysconfig/network-scripts目录下生成如下三个文件
vi ifcfg-bond1
DEVICE=bond1
BOOTPROTO=static
IPADDR=10.4.124.*
NETMASK=255.255.255.224
GATEWAY=10.4.124.*
ONBOOT=YES
TYPE=Ethernet
USERCTL=no
BONDING_OPTS="miimon=100 mode=1"
vi ifcfg-eth4
DEVICE=eth4
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond1
SLAVE=yes
vi ifcfg-eth5
DEVICE=eth5
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond1
SLAVE=yes
2,修改modprobe.conf文件按,添加一行
vi /etc/modprobe.conf
alias bond1 bonding
3,重启网络
service network restart
vi ifcfg-bond1
DEVICE=bond1
BOOTPROTO=static
IPADDR=10.4.124.*
NETMASK=255.255.255.224
GATEWAY=10.4.124.*
ONBOOT=YES
TYPE=Ethernet
USERCTL=no
BONDING_OPTS="miimon=100 mode=1"
vi ifcfg-eth4
DEVICE=eth4
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond1
SLAVE=yes
vi ifcfg-eth5
DEVICE=eth5
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond1
SLAVE=yes
2,修改modprobe.conf文件按,添加一行
vi /etc/modprobe.conf
alias bond1 bonding
3,重启网络
service network restart