作者/来源:yixinu.com
栏目:运维/编程
日期:2012-06-04 02:35:15
1、安装内核文档包
[root@localhost network-scripts]# yum install kernel-doc -y2、进入到这个目录
[root@localhost network-scripts]# cd /usr/share/doc/kernel-doc-2.6.32/Documentation/3、找到这个文件[bonding],打开查看
[root@localhost Documentation]# find -iname "bond*" ./networking/bonding.txt [root@localhost Documentation]# vim ./networking/bonding.txt
4、查看有没有这个模块
[root@localhost Documentation]# modprobe -l bonding kernel/drivers/net/bonding/bonding.ko [root@localhost Documentation]# lsmod | grep bond
modinfo bonding 注意查看模块配置参数
5、配置参数并装载模块
[root@localhost Documentation]# vim /etc/modprobe.d/bond.conf alias bond0 bonding options bond0 mode=1 miimon=1000 use_carrier=0
[root@localhost Documentation]# modprobe bonding [root@localhost Documentation]# lsmod | grep bonding bonding 109558 0 ipv6 264641 34 bonding,ip6t_REJECT,nf_conntrack_ipv6,nf_defrag_ipv6
6、编辑网卡配置文件
[root@localhost network-scripts]# vim *eth0 DEVICE="eth0" BOOTPROTO="none" HWADDR="00:0C:29:11:38:69" ONBOOT="yes" MASTER="bond0" SLAVE="yes" [root@localhost network-scripts]# vim *eth1 DEVICE="eth1" BOOTPROTO="none" HWADDR="00:0C:29:11:76:83" ONBOOT="yes" MASTER="bond0" SLAVE="yes" [root@localhost network-scripts]# vim ifcfg-bond0 DEVICE="bond0" BOOTPROTO="none" IPADDR="192.168.73.186" NETMASK="255.255.255.0" ONBOOT="yes" MASTER="bond0" SLAVE="yes"
7、重新启动网络