Page 1 of 1
Network bridge on stretch
Posted: Fri Dec 01, 2017 11:42 pm
by user321
Hello,
I need to have a network bridge to use it with lxc containers.
I used this code in /etc/network/interfaces on Stretch 2017-08-16, but on Stretch 2017-09-07 the network connection fails if I use it:
Code: Select all
auto br0
iface br0 inet dhcp
bridge_ports enxb827ebeb1620
bridge_stp off
bridge_fd 0
bridge_maxwait 0
I want to use it on Stretch 2017-09-07. Another problem is that predictable interface names does not work on this version. The interface names are eth0 and wlan0. Can anyone help me?
Re: Network bridge on stretch
Posted: Sat Dec 02, 2017 1:05 am
by DougieLawson
There's a raspi-config option in latest Stretch to re-enable predictable names.
Re: Network bridge on stretch
Posted: Sat Dec 02, 2017 1:39 am
by SurferTim
Which interfaces do you want to bridge? I see only one interface on br0 in your /etc/network/interfaces file.
Re: Network bridge on stretch
Posted: Sat Dec 02, 2017 1:59 pm
by user321
I don't want to bridge two interfaces. I need an additional interface for lxc.
I followed this tutorial
https://wiki.debian.org/LXC/SimpleBridge (Host device as bridge)
Re: Network bridge on stretch
Posted: Sat Dec 02, 2017 3:07 pm
by epoch1970
To rephrase what DougieLawson said,
- either reinstate the previous behaviour regarding network interfaces names via raspi-config, this was changed between the 2 releases you've used
- or "bridge-ports eth0" from now on.
Re: Network bridge on stretch
Posted: Sat Dec 02, 2017 7:13 pm
by user321
Is it possible to do this with wlan0? I read that wifi does not support bridging because it is not possible to have multiple mac adresses for one wifi interface.
Re: Network bridge on stretch
Posted: Sun Dec 03, 2017 2:05 pm
by sparkie777
user321 wrote: ↑Sat Dec 02, 2017 7:13 pm
I read that wifi does not support bridging because it is not possible to have multiple mac adresses for one wifi interface.
it depends. Basically bridging is possible always.
- wlan configured as a wireless access point easily supports bridging
- wlan configured as a wireless client basically supports bridging too (with some constraints). And only with some tweaking around. Further reading:
BridgeNetworkConnectionsProxyArp - Debian Wiki (this overcomes the "multiple mac addresses for one wifi interface" problem)
Re: Network bridge on stretch
Posted: Sun Dec 03, 2017 3:03 pm
by epoch1970
sparkie777 wrote: ↑Sun Dec 03, 2017 2:05 pm
- wlan configured as a wireless client basically supports bridging
not
FTFY.
Let's keep it simple and clear. It does not work out of the box, hacking around this limit is fiddly and once you're a hero and done you'll be rewarded with poor service.
Just use routing in this case. There are many "bridging wifi" threads on this forum that actually relate to routing...
Re: Network bridge on stretch
Posted: Sun Dec 03, 2017 3:51 pm
by sparkie777
epoch1970 wrote: ↑Sun Dec 03, 2017 3:03 pm
It does not work out of the box,
that's what I said.