When testing trunk setup on one of my servers I found out that if I change just
the trunkproto, for example from roundrobin to loadbalance the proto will be
changed, but the member ports will not be re-added, leading to the trunk using
only one of the ports from taht point on...
I've attacehd a short fix for this.
greets
Dariusz Swiderski
--
A mouse is a device used to point at the xterm you want to type in.
--- sys/net/if_trunk.c.orig
+++ sys/net/if_trunk.c
@@ -646,6 +646,8 @@
error = EPROTONOSUPPORT;
break;
}
+ if (ra->ra_proto == tr->tr_proto)
+ break;
/*
* Use of ifp->if_input and ac->ac_trunkport is
@@ -1442,7 +1444,8 @@
arc4random_buf(&lb->lb_key, sizeof(lb->lb_key));
tr->tr_psc = (caddr_t)lb;
- return (0);
+ /* Ports may already exist when changing the trunk protocol. */
+ return (trunk_lb_porttable(tr, NULL));
}
int