* [Bridge] Bridge MAC selection
@ 2008-06-11 8:27 Dietmar Maurer
2008-06-11 15:58 ` Stephen Hemminger
0 siblings, 1 reply; 7+ messages in thread
From: Dietmar Maurer @ 2008-06-11 8:27 UTC (permalink / raw)
To: bridge
Hi all,
We provid a management plattform for virtual machines (pve.proxmox.com),
and
use a bridge access the network.
Currently the system choose the lowest MAC for the purposes of STP
and also assigns this MAC to the bridge. This is a problem because the
Bridge MAC changes when we start/stop virtual machines - leading to
Network outage for several seconds.
Using the first (insteasd of lowest) MAC would avoid the problem. So are
There any side effects with the following patch?
--- br_stp_if.c.org 2008-06-11 09:15:16.000000000 +0200
+++ br_stp_if.c 2008-06-11 09:44:53.000000000 +0200
@@ -217,10 +217,7 @@
struct net_bridge_port *p;
list_for_each_entry(p, &br->port_list, list) {
- if (addr == br_mac_zero ||
- memcmp(p->dev->dev_addr, addr, ETH_ALEN) < 0)
- addr = p->dev->dev_addr;
-
+ addr = p->dev->dev_addr;
}
if (compare_ether_addr(br->bridge_id.addr, addr))
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [Bridge] Bridge MAC selection
2008-06-11 8:27 [Bridge] Bridge MAC selection Dietmar Maurer
@ 2008-06-11 15:58 ` Stephen Hemminger
2008-06-12 4:51 ` Dietmar Maurer
0 siblings, 1 reply; 7+ messages in thread
From: Stephen Hemminger @ 2008-06-11 15:58 UTC (permalink / raw)
To: Dietmar Maurer; +Cc: bridge
On Wed, 11 Jun 2008 10:27:54 +0200
"Dietmar Maurer" <dietmar@proxmox.com> wrote:
> Hi all,
>
> We provid a management plattform for virtual machines (pve.proxmox.com),
> and
> use a bridge access the network.
>
> Currently the system choose the lowest MAC for the purposes of STP
> and also assigns this MAC to the bridge. This is a problem because the
> Bridge MAC changes when we start/stop virtual machines - leading to
> Network outage for several seconds.
>
> Using the first (insteasd of lowest) MAC would avoid the problem. So are
>
> There any side effects with the following patch?
Not for you. But if it got changed now, it would surprise the existing
users (change in ABI behaviour).
So if you need a particular mac address, you can set it with other tools
(ip or ifconfig).
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Bridge] Bridge MAC selection
2008-06-11 15:58 ` Stephen Hemminger
@ 2008-06-12 4:51 ` Dietmar Maurer
2008-06-12 10:29 ` Patrick McHardy
0 siblings, 1 reply; 7+ messages in thread
From: Dietmar Maurer @ 2008-06-12 4:51 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: bridge
> > There any side effects with the following patch?
>
> Not for you. But if it got changed now, it would surprise the
> existing users (change in ABI behaviour).
>
> So if you need a particular mac address, you can set it with
> other tools (ip or ifconfig).
You are right, I can set the Hw address with ifconfig - but
any 'brctl addif' later resets the address, so that is simply not
usable.
- Dietmar
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Bridge] Bridge MAC selection
2008-06-12 4:51 ` Dietmar Maurer
@ 2008-06-12 10:29 ` Patrick McHardy
2008-06-12 11:10 ` Dietmar Maurer
0 siblings, 1 reply; 7+ messages in thread
From: Patrick McHardy @ 2008-06-12 10:29 UTC (permalink / raw)
To: Dietmar Maurer; +Cc: Stephen Hemminger, bridge
Dietmar Maurer wrote:
>>> There any side effects with the following patch?
>> Not for you. But if it got changed now, it would surprise the
>> existing users (change in ABI behaviour).
>>
>> So if you need a particular mac address, you can set it with
>> other tools (ip or ifconfig).
>
> You are right, I can set the Hw address with ifconfig - but
> any 'brctl addif' later resets the address, so that is simply not
> usable.
Maybe add a persistent option to keep the manually configured
mac? Or simply disable this behaviour if a mac is configured
manually automatically. If someone does this, its probably
fair to assume he doesn't expect the address to change.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Bridge] Bridge MAC selection
2008-06-12 10:29 ` Patrick McHardy
@ 2008-06-12 11:10 ` Dietmar Maurer
2008-06-12 13:22 ` Andy Gospodarek
0 siblings, 1 reply; 7+ messages in thread
From: Dietmar Maurer @ 2008-06-12 11:10 UTC (permalink / raw)
To: bridge
>>> There any side effects with the following patch?
>> Not for you. But if it got changed now, it would surprise the
>> existing users (change in ABI behaviour).
If there are no other side effects, I wonder whats better:
A.) unexpected Network failures due to mac changes
B.) surprised users (does anybody depend on such behavour?)
I vote for A.)
- Dietmar
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Bridge] Bridge MAC selection
2008-06-12 11:10 ` Dietmar Maurer
@ 2008-06-12 13:22 ` Andy Gospodarek
2008-06-12 13:39 ` Patrick McHardy
0 siblings, 1 reply; 7+ messages in thread
From: Andy Gospodarek @ 2008-06-12 13:22 UTC (permalink / raw)
To: Dietmar Maurer; +Cc: bridge
On Thu, Jun 12, 2008 at 7:10 AM, Dietmar Maurer <dietmar@proxmox.com> wrote:
>>>> There any side effects with the following patch?
>>> Not for you. But if it got changed now, it would surprise the
>>> existing users (change in ABI behaviour).
>
> If there are no other side effects, I wonder whats better:
>
> A.) unexpected Network failures due to mac changes
>
> B.) surprised users (does anybody depend on such behavour?)
>
> I vote for A.)
>
> - Dietmar
>
You might think A is a better option, but option B is frowned upon. I
understand you desire your change the behavior to meet your needs, but
Patrick's suggestion to add a module parameter to tweak this behavior
based on a module option is probably better than simply changing the
existing functionality to meet your needs.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Bridge] Bridge MAC selection
2008-06-12 13:22 ` Andy Gospodarek
@ 2008-06-12 13:39 ` Patrick McHardy
0 siblings, 0 replies; 7+ messages in thread
From: Patrick McHardy @ 2008-06-12 13:39 UTC (permalink / raw)
To: Andy Gospodarek; +Cc: bridge
Andy Gospodarek wrote:
> On Thu, Jun 12, 2008 at 7:10 AM, Dietmar Maurer <dietmar@proxmox.com> wrote:
>>>>> There any side effects with the following patch?
>>>> Not for you. But if it got changed now, it would surprise the
>>>> existing users (change in ABI behaviour).
>> If there are no other side effects, I wonder whats better:
>>
>> A.) unexpected Network failures due to mac changes
>>
>> B.) surprised users (does anybody depend on such behavour?)
>>
>> I vote for A.)
>>
>> - Dietmar
>>
>
> You might think A is a better option, but option B is frowned upon. I
> understand you desire your change the behavior to meet your needs, but
> Patrick's suggestion to add a module parameter to tweak this behavior
> based on a module option is probably better than simply changing the
> existing functionality to meet your needs.
I actually meant a brctl parameter, module parameters suck as
configuration interfaces. But I think the second option is
better, just disable this behaviour automatically when the
address is configured manually.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2008-06-12 13:39 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-11 8:27 [Bridge] Bridge MAC selection Dietmar Maurer
2008-06-11 15:58 ` Stephen Hemminger
2008-06-12 4:51 ` Dietmar Maurer
2008-06-12 10:29 ` Patrick McHardy
2008-06-12 11:10 ` Dietmar Maurer
2008-06-12 13:22 ` Andy Gospodarek
2008-06-12 13:39 ` Patrick McHardy
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.