Bind multiple NICs to centos

Source: Internet
Author: User
RHEL6 is slightly different from the previous RedhatLinux version in terms of network configuration. This article describes how to bind multiple NICs in RHEL6. 1. create the binding interface bond0 [root @ Hostname ~] # Touch/etc/sysconfig/network-scripts/ifcfg-bond0 [root @ Hostname ~] # Cat/etc/sysconfig/network

RHEL6 is slightly different from the previous Redhat Linux version in terms of network configuration. This article describes how to bind multiple NICs in RHEL6.

1. create the binding interface bond0

[root@Hostname ~]#touch /etc/sysconfig/network-scripts/ifcfg-bond0[root@Hostname ~]#cat /etc/sysconfig/network-scripts/ifcfg-bond0DEVICE=bond0ONBOOT=yesIPADDR=172.24.254.13BOOTPROTO=noneNETMASK=255.255.255.0TYPE=EthernetGATEWAY=172.24.254.91BONDING_OPTS="MODE=0 MIIMON=1000"

2. configure the physical interfaces eth2, eth3, eth4, and eth5

[root@Hostname ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth2DEVICE=eth2ONBOOT=yesBOOTPROTO=noneTYPE=Ethernet[root@Hostname ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth3DEVICE=eth3ONBOOT=yesBOOTPROTO=noneTYPE=Ethernet[root@Hostname ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth4DEVICE=eth4ONBOOT=yesBOOTPROTO=noneTYPE=Ethernet[root@Hostname ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth5DEVICE=eth5ONBOOT=yesBOOTPROTO=noneTYPE=Ethernet

3. configure the Bonding configuration file/etc/modprobe. d/bond0.conf

[root@Hostname ~]# cat /etc/modprobe.d/bond0.confalias bond0 bonding

4. modify the system configuration file/etc/rc. local and add the following content to the end of the file:

ifenslave bond0 eth2 eth3 eth4 eth5

5. restart the system to make the configuration take effect.


For more information, see:
Http://www.linuxtopia.org/online_books/rhel6/rhel_6_deployment/rhel_6_deployment_sec-Using_Channel_Bonding.html

In addition, if you run the following command in RHEL6:
Service network restart

The following error is reported:
Bringing up interface bond0: Error: Connection activation failed: Device not managed by NetworkManager

This error occurs because the network is managed by the NetworkManager service by default in the system and can be stopped:

[root@Hostname ~]#chkconfig NetworkManager off[root@Hostname ~]#service NetworkManager stop[root@Hostname ~]#chkconfig network on[root@Hostname ~]#service network restart

Note that NetworkManager is case sensitive.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.