NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

About bridges



Hey!

I was toying with bridging three of the four ethernet ports on an pcengines
apu4d4 recently and bumped into something that made me unsure if I understood
how to use bridges correctly.

My setup is like this:

wm1 configured with an address
wm2 no address, just up
wm3 same as 2

and the bridge:

brconfig bridge0 add wm1 stp wm1 add wm2 stp wm2 add wm3 stp wm3

This all works, packets flow and addresses are learned on all interfaces, but
ONLY if there is a cable with a link on wm1. It seems to be that if there is
no link on wm1 the interface (status: no carrier and address shows <DETACHED>)
gets disabled in the bridge, which kind of sucks because then the host has no
address and communication stops.

I tried looking for pseudo devices that I could use on the bridge for the host
interface so that it wouldn't matter which port you plug a network in to, but
the only thing I could attach to the bridge was a tap device and using that as
the host if doesn't seem to work.

The only other devices that I've done bridging on (except my Xen host, but
that's a load of virtual interfaces connected to one real one which always had
a link) are Mikrotik routerboards and there you could set an address on the
bridge device itself; something that you cannot do on netbsd, apparently.

So how is this supposed to work? Can I force the interface with an address to
stay enabled somehow or is there a pseudo-device that I haven't found that I
should be using?

Staffan



Home | Main Index | Thread Index | Old Index