码迷,mamicode.com
首页 > 系统相关 > 详细

LINUX 双网卡绑定

时间:2014-04-29 17:17:47      阅读:639      评论:0      收藏:0      [点我收藏+]

标签:re   cti   c   linux   ar   user   

cd /etc/sysconfig/network-scripts

cp ifcfg-eth0  bak.ifcfg-eth0

cp ifcfg-eth1  bak.ifcfg-eth1

 

vi ifcfg-bond0

DEVICE=bond0

BROADCAST=192.168.190.255

IPADDR=192.168.190.11

NETMASK=255.255.255.0

GATEWAY=192.168.190.1

ONBOOT=yes

USERCTL=no

BOOTPROTO=none

PEERDNS=yes

BONDING_OPTS=”modo=1 miimon=100”

 

vi ifcfg-eth0

DEVICE=eth0

ONBOOT=yes

MASTER=bondo

BOOTPROTO=none

SLAVE=yes

USERCTL=no

 

vi ifcfg-eht1

DEVICE=eth1

ONBOOT=yes

MASTER=bondo

BOOTPROTO=none

SLAVE=yes

USERCTL=no

 

service NetworkManager stop     //停止NetworkManager服务

chkconfig NetworkManager off    //禁止NetworkManager服务开机启动

 

reboot

 

重启成功后检查 cat /proc/net/bonding/bond0

若为一下则成功:

Ethernet Channel Bonding Driver: v3.6.0 (September 26, 2009)

Bonding Mode: fault-tolerance (active-backup)

Primary Slave: None

Currently Active Slave: eth0

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: e4:1f:13:80:ee:93

Slave queue ID: 0

Slave Interface: eth1

MII Status: up

Speed: 1000 Mbps

Duplex: full

Link Failure Count: 1

Permanent HW addr: e4:1f:13:80:ee:94

Slave queue ID: 0

LINUX 双网卡绑定,布布扣,bubuko.com

LINUX 双网卡绑定

标签:re   cti   c   linux   ar   user   

原文地址:http://www.cnblogs.com/sinnerliu/p/3699725.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!