You are not logged in.

#1 2009-09-28 18:00:27

DrMikeDuke
Member
From: Australia
Registered: 2008-05-12
Posts: 79
Website

[Tentatively-Fixed] fixed MAC address for ethernet bonding?

EDIT: See my findings, below.

Hallo all,

Been doing a bit of research but turned up a blank.
I have standard NIC bonding (teaming if you will..) enabled as per the wiki.
My question is thus: sometimes eth0's MAC address will be used and sometimes
eth1's will be used. This really screws with the way I give it a static address in my
firewall (pfsense).
Is there any way to force bond0 (my bonded interface) to use a SPECIFIC mac address?

I know I could set a static IP but I prefer the administrative ease of being able to allocate
IP's from a central source.

Thanks!

Mike.

Last edited by DrMikeDuke (2009-09-29 13:28:52)


Workstation: Core i7 2600k | Asus PBZ68-V/GEN3 | 8GB DDR3-2000 | Gainward GLH GTX570 | Velociraptor 300 | AntecSS 850W | Essence ST | Corsair 800D | Win7x64 Pro/Arch LinuxX64
Server: 2x Six-Core AMD Opteron Processor 8439 SE, 64GB DDR2 ECC, Tyan S2932-SI, Areca ARC-1230 Raid, PCP&C 1Kw PSU, LSi FusionMPT Ultra320 SCSI/Tandberg LTO4 Autoloader
Laptop: Alienware M14xR3

Offline

#2 2009-09-28 22:39:43

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: [Tentatively-Fixed] fixed MAC address for ethernet bonding?

Set both eth0 and eth1 to have the same mac before the bond comes up?

ifconfig eth0 hw ether AB:CD:EF:12:34:56
ifconfig eth1 hw ether AB:CD:EF:12:34:56

Haven't got around to bonding in Arch yet, so not sure exactly where would be best to put this...

Offline

#3 2009-09-29 09:13:25

DrMikeDuke
Member
From: Australia
Registered: 2008-05-12
Posts: 79
Website

Re: [Tentatively-Fixed] fixed MAC address for ethernet bonding?

fukawi2 wrote:

Set both eth0 and eth1 to have the same mac before the bond comes up?

ifconfig eth0 hw ether AB:CD:EF:12:34:56
ifconfig eth1 hw ether AB:CD:EF:12:34:56

Haven't got around to bonding in Arch yet, so not sure exactly where would be best to put this...

yeah thats funny you should say I was playing around with that prior to posting, but I didn't figure out *where*
to put it. If any other arch'ers want to enlighten us IDM, glad to learn something new each day big_smile


Workstation: Core i7 2600k | Asus PBZ68-V/GEN3 | 8GB DDR3-2000 | Gainward GLH GTX570 | Velociraptor 300 | AntecSS 850W | Essence ST | Corsair 800D | Win7x64 Pro/Arch LinuxX64
Server: 2x Six-Core AMD Opteron Processor 8439 SE, 64GB DDR2 ECC, Tyan S2932-SI, Areca ARC-1230 Raid, PCP&C 1Kw PSU, LSi FusionMPT Ultra320 SCSI/Tandberg LTO4 Autoloader
Laptop: Alienware M14xR3

Offline

#4 2009-09-29 09:44:47

DrMikeDuke
Member
From: Australia
Registered: 2008-05-12
Posts: 79
Website

Re: [Tentatively-Fixed] fixed MAC address for ethernet bonding?

Edit: This seems to have solved the problem, but as it is intermitent I cant be 100% sure. Can anyone else confirm this?
It seems this might be useful to others since this MAC problem is in theory applicable to anyone who uses bonding.

Inspired from this website http://www.geocities.com/SiliconValley/ … 6/net.html
I am going to try the following, will report back (if I still can haha!)

/etc/rc.d/network

bond_up()
{
#KEYWORD
        /sbin/ifconfig bond0 hw ether 00:02:b3:3c:50:bf || error=1
        for ifline in ${BOND_INTERFACES[@]}; do
                if [ "$ifline" = "${ifline#!}" ]; then
                        eval bondcfg="\$bond_${ifline}"
                        if [ -n "${bondcfg}" ]; then
                                /sbin/ifenslave $ifline $bondcfg || error=1
                        fi
                fi
        done
}

and in /etc/rc.local to fix my DHCP timeout issues

#!/bin/bash
#
# /etc/rc.local: Local multi-user startup script.
#
dhcpcd -k bond0
dhcpcd -nd bond0

Last edited by DrMikeDuke (2009-09-29 09:55:43)


Workstation: Core i7 2600k | Asus PBZ68-V/GEN3 | 8GB DDR3-2000 | Gainward GLH GTX570 | Velociraptor 300 | AntecSS 850W | Essence ST | Corsair 800D | Win7x64 Pro/Arch LinuxX64
Server: 2x Six-Core AMD Opteron Processor 8439 SE, 64GB DDR2 ECC, Tyan S2932-SI, Areca ARC-1230 Raid, PCP&C 1Kw PSU, LSi FusionMPT Ultra320 SCSI/Tandberg LTO4 Autoloader
Laptop: Alienware M14xR3

Offline

Board footer

Powered by FluxBB