?
Solved

Why bonding not work well? (linux Centos)

Posted on 2011-03-17
8
Medium Priority
?
1,169 Views
Last Modified: 2012-08-13
I config bonding my server like this:
eth0:
eth1 (LAN)
eth2:

I config bonding bond0, eth0 and eth2:
#BOND 0:
DEVICE=bond0
IPADDR=x.x.x.153
NETMASK=255.255.255.0
NETWORK=
BROADCAST=
GATEWAY=x.x.x.158
ONBOOT=yes
BOOTPROTO=none
USERCTL=no

#eth0
# Intel Corporation 82574L Gigabit Network Connection
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
HWADDR=00:25:90:0d:53:90
TYPE=Ethernet
SLAVE=yes
MASTER=bond0

#eth2
# Intel Corporation 82574L Gigabit Network Connection
DEVICE=eth2
BOOTPROTO=none
ONBOOT=yes
HWADDR=00:25:90:0d:53:92
TYPE=Ethernet
SLAVE=yes
MASTER=bond0

#and /etc/modprobe.conf like this:
alias eth0 e1000e
alias eth1 e1000e
alias eth2 e1000e
alias eth3 e1000e
alias scsi_hostadapter ahci
alias bond0 bonding
options bond0 miimon=100 mode=2 use_carrier=1 xmit_hash_policy=1

-------------------------------------------
But when apply, restart server, restart network, I see data go out bond0 with 1000Mbit/s, but only go out eth2 , not pass eth0 (0kbit/s). Bandwidth of system = bond0 = eth2 , have not include eth0 in this case.
Normal of bonding, bond0 must = eth0+ eth2!

Why that?
Thank you!

0
Comment
Question by:redstar01
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 3

Assisted Solution

by:Abhishek_Chib
Abhishek_Chib earned 1600 total points
ID: 35163033
Hi,

First change Mode to : mode=balance-alb or mode=6 (Balance ALB)

Follow the steps :

# modprobe bonding
# service network restart

Paste the result :
# less /proc/net/bonding/bond0

I am suspecting, you network switch is supporting mode=2 (Balance XOR)

Check URL : http://www.cyberciti.biz/howto/question/static/linux-ethernet-bonding-driver-howto.php

Section : "6. Switch Configuration"

0
 
LVL 3

Assisted Solution

by:Abhishek_Chib
Abhishek_Chib earned 1600 total points
ID: 35163047
Sorry, typo problem - I am suspecting, your network switch is not supporting mode=2 (Balance XOR)
0
 
LVL 6

Assisted Solution

by:de2Zotjes
de2Zotjes earned 400 total points
ID: 35163907
The mode 2 (balance xor) does not require any special config or support on the switch.

In your config there is a deviation from the documentation. You have "xmit_hash_policy=1" where the documentation says to use "xmit_hash_policy=layer2" (same url as shown above)

Also the balance xor mode will not put the traffic destined for a single remote host over 2 nics. To see whether traffic is spread over multiple nics you need to set up connections from different mac-addresses (multiple machines). Was that the case during your test?
0
Does Your Cloud Backup Use Blockchain Technology?

Blockchain technology has already revolutionized finance thanks to Bitcoin. Now it's disrupting other areas, including the realm of data protection. Learn how blockchain is now being used to authenticate backup files and keep them safe from hackers.

 

Author Comment

by:redstar01
ID: 35165015
in ifconfig:

eth0      Link encap:Ethernet  HWaddr 00:25:90:0D:53:90
          UP BROADCAST SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Memory:fb3e0000-fb400000

eth2      Link encap:Ethernet  HWaddr 00:25:90:0D:53:90
          UP BROADCAST RUNNING SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:6205161239 errors:0 dropped:11 overruns:0 frame:0
          TX packets:11390153863 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:387930880250 (361.2 GiB)  TX bytes:16718240199110 (15.2 TiB)
          Memory:fb5e0000-fb600000

Yes, Is there any problem with MAC address? because In config file, and In device manager, I found
eth0 is 00:25:90:0D:53:90
eth1 is 00:25:90:0D:53:91
eth2 is 00:25:90:0D:53:92

But when has bonding, the MAC address of eth2 is the same eth0 (eth1 is 00:25:90:0D:53:90), like result!

So, bonding make MAC address change?

0
 

Author Comment

by:redstar01
ID: 35165031
in ifconfig:

eth0      Link encap:Ethernet  HWaddr 00:25:90:0D:53:90
          UP BROADCAST SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Memory:fb3e0000-fb400000

eth2      Link encap:Ethernet  HWaddr 00:25:90:0D:53:90
          UP BROADCAST RUNNING SLAVE MULTICAST  MTU:1500  Metric:1
          RX packets:6205161239 errors:0 dropped:11 overruns:0 frame:0
          TX packets:11390153863 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:387930880250 (361.2 GiB)  TX bytes:16718240199110 (15.2 TiB)
          Memory:fb5e0000-fb600000

Yes, Is there any problem with MAC address? because In config file, and In device manager, I found
eth0 is 00:25:90:0D:53:90
eth1 is 00:25:90:0D:53:91
eth2 is 00:25:90:0D:53:92

But when I apply bonding, the MAC address of eth2 is the same eth0 (00:25:90:0D:53:90), like ifconfig result!

So, bonding makes MAC address change?
0
 

Author Comment

by:redstar01
ID: 35165157
And the result of command::
less /proc/net/bonding/bond0


Ethernet Channel Bonding Driver: v3.4.0 (October 7, 2008)

Bonding Mode: load balancing (xor)
Transmit Hash Policy: layer3+4 (1)
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 0
Down Delay (ms): 0

Slave Interface: eth0
MII Status: down
Link Failure Count: 0
Permanent HW addr: 00:25:90:0d:53:90

Slave Interface: eth2
MII Status: up
Link Failure Count: 0
Permanent HW addr: 00:25:90:0d:53:92
0
 

Author Comment

by:redstar01
ID: 35170361
I'm also running VMwareWorkstation on this server, Is It affect?
0
 
LVL 3

Accepted Solution

by:
Abhishek_Chib earned 1600 total points
ID: 35174272
redstar01, can you check why eth0 showing down. Check with VMware logs
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How many times have you wanted to quickly do the same thing to a list but found yourself typing it again and again? I first figured out a small time saver with the up arrow to recall the last command but that can only get you so far if you have a bi…
If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Suggested Courses
Course of the Month13 days, 18 hours left to enroll

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question