LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 04-25-2006, 09:03 PM   #1
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 66
bonding problems


I am currently using the bonding driver from the Linux kernel to provide an active backup ethernet interface on my server.

My setup is consistent with how the Linux Ethernet Bonding Driver Howto suggests one does HA bonding. In other words, I have two switches on the same VLAN, one slave plugs into each switch.

Looking at the output of the bonding driver (cat /proc/net/bonding/bond0) I see the following:

Code:
[root@tcpcrossbar1 root]# cat /proc/net/bonding/bond0 
Ethernet Channel Bonding Driver: v2.6.0 (January 14, 2004)

Bonding Mode: fault-tolerance (active-backup)
Primary Slave: None
Currently Active Slave: eth3
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 0
Down Delay (ms): 0

Slave Interface: eth2
MII Status: up
Link Failure Count: 1
Permanent HW addr: 00:14:c2:3f:0a:63

Slave Interface: eth3
MII Status: up
Link Failure Count: 0
Permanent HW addr: 00:14:c2:3f:0a:50
Now, according to the driver documentation the inactive interface should be just that, inactive. The problem I am seeing is there is a steady stream of traffic coming into the primary interface but I am also seeing a consistent and steady stream of traffic (though a lot less traffic) coming into the inactive interface. Only the active interface ever sends data. Now, where this really becomes a problem is that my core switches are complaining of duplicate mac addresses on the inactive interface port.

Has anyone experienced these problems and if so do you have any suggestions?

John
 
Old 04-26-2006, 07:38 PM   #2
williamwbishop
Member
 
Registered: Feb 2003
Location: god's judge
Posts: 376

Rep: Reputation: 30
Can you post your configuration?
 
Old 04-28-2006, 09:21 AM   #3
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Original Poster
Rep: Reputation: 66
Well.. what we do is a bit of a kluge... for various application reasons we use RHEL3 which does not support bonding with DHCP... However, we need DHCP in conjunction with our blades because we have far too many machines and we want a central place to configure IPs (it is DHCP but each server has a static address assigned to its MAC).

So what I've done is put the configuration for eth0 to boot like a standard DHCP network card (eth1 is not configured by the OS). I then have an init script that runs directly after the networking script that does the following:

Code:
#!/bin/bash
ETH0_MAC=$( ifconfig eth0 |awk '/HWaddr/{print $5}' )
ETH0_IP=$( ifconfig eth0 |awk -F: '/inet addr/{print $2}' |awk '{print $1}')
ETH0_NETMASK=$( ifconfig eth0 |awk -F: '/Mask/{print $4}' )

case "$1" in
  start)
  echo "Bonding eth0 and eth1"
  /sbin/ifdown eth0
  /sbin/ifdown eth1
  /sbin/modprobe bonding mode=1 miimon=100 primary=eth0
  /sbin/ifconfig bond0 $ETH0_IP netmask $ETH0_NETMASK hw ether $ETH0_MAC
  /sbin/ifenslave bond0 eth0
  /sbin/ifenslave bond0 eth1
  /sbin/route add default gw XXX.XXX.XXX.XXX bond0
  ;;
  stop)
  /sbin/ifdown eth0
  /sbin/ifdown eth1
  /sbin/ifconfig bond0 down
  /sbin/rmmod bonding
  ;;
  restart|reload)
  $0 stop
  $0 start
  ;;
  status)
  cat /proc/net/bonding/bond0
  ;;
  *)
  echo $"Usage: $0 {start|stop|status|restart|reload}"
  exit 1
esac
Again, this is somewhat of a hack but RedHat didn't support DHCP w/ bonding until RHEL4 and our application server didn't support RHEL4 until recently.

I did install a new version of the nic card and bonding drivers from HP (the devices in question are HP BL25p's) and I'll give that a shot.

If you have any other suggestions I'm all ears.

John

Last edited by jtshaw; 04-28-2006 at 12:45 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
bonding aylov Linux - Networking 7 09-03-2007 11:24 PM
Help with bonding bwoodruff Linux - Networking 4 11-09-2006 02:14 PM
Bonding on SUSE Bk66 Linux - Networking 1 12-09-2003 09:39 AM
Bonding and sniffing.... sdandeker Linux - Security 4 09-26-2003 06:53 AM
Ethernet bonding trycoon Linux - Networking 7 07-23-2002 10:05 AM


All times are GMT -5. The time now is 07:11 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration