Operating System - Linux
1827997 Members
2894 Online
109973 Solutions
New Discussion

Re: how to combine multiple nics

 
SOLVED
Go to solution
Maaz
Valued Contributor

how to combine multiple nics

OS: SUSE Linux 10 SP1

is it possible to combine 2 nics ?
if one nic goes down due to hardware error(malfunction) the other nic will continue to work, so that services remains available to the client, and machine remains available on the network.

Regards
Maa
5 REPLIES 5
Ivan Ferreira
Honored Contributor

Re: how to combine multiple nics

Linux provides ethernet bonding. The bonding kernel module allows the configuration of redundant NICs.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Svetoslav Gyurov
Valued Contributor
Solution

Re: how to combine multiple nics

Hi,

Yes it is possible by using the linux ethernet bonding driver:

1. configure the bond interface
vi /etc/sysconfig/network/ifcfg-bond0
BOOTPROTO="static"
BROADCAST="10.0.0.255"
IPADDR="10.0.0.10"
NETMASK="255.255.255.0"
NETWORK=""
REMOTE_IPADDR=""
STARTMODE="onboot"
BONDING_MASTER="yes"
BONDING_MODULE_OPTS="mode=balance-alb miimon=100"
BONDING_SLAVE0="eth0"
BONDING_SLAVE1="eth1"


2. make alias and set options for bonding options
# load and configure module
alias bond0 bonding
options bond0 mode=balance-alb miimon=100
alias bond1 bonding
options bond1 mode=balance-alb miimon=100


3. remove old records
vi ifcfg-id-xx:xx:xx:xx:xx:xx
BOOTPROTO='none'
STARTMODE='off'


4. test
modprobe bonding
service network restart
cat /proc/net/bonding/bond0


Typical bonding configuration should look like this:
sve@angmar:~/project/mvn$ cat bond0
Ethernet Channel Bonding Driver: v3.0.1 (January 9, 2006)

Bonding Mode: adaptive load balancing
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
Link Failure Count: 0
Permanent HW addr: 00:19:bb:30:21:d0

Slave Interface: eth1
MII Status: up
Link Failure Count: 0
Permanent HW addr: 00:19:bb:30:21:cf

For more information refer to the kernel documentaion:
/usr/src/linux/Documentation/networking/bonding.txt

Good luck!

--
sve
Maaz
Valued Contributor

Re: how to combine multiple nics

Thanks Ivan Ferreira, and Svetoslav Gyurov

does "mode=balance-alb" provides High Availability and/or fault tolerance ?

Svetoslav Gyurov, in SUSE options are provided in single quotes in the nic configuration file.

there is no need to configure in /etc/modprobe.conf
I also tried to configure the bonding using YaST, and using mouse clicks its done(nice tool). Yast also doesnt modify the /etc/modprobe.conf.

Svetoslav Gyurov
Valued Contributor

Re: how to combine multiple nics

Maaz,

Yes it provides failover in case of a failure of one of the nics. I used this feature to provide HA to the network interfaces in regard to Oracle RAC. I used to have two servers each with four nics connected to two (stacked) switches. So I had two bonded interfaces, one for the public and one for the private network and I never used to have problems with this setup.

Regards,
sve
Maaz
Valued Contributor

Re: how to combine multiple nics

Thanks once again Dear Svetoslav Gyurov