Hello,
I am here because after reading all the tutorial for creating a bridge it still not working.
What I have it is a box so my lan is 192.168.1…
My server need to have a static IP for example 192.168.1.160
But when I am trying to build the bridge lxc-net erase the network/interface option and I lost the Broadcast.
And from my container I have no connection.
my configuration is this :
/etc/network/interfaces
allow-hotplug enp1s0
auto lxcbr0
iface lxcbr0 inet dhcp
bridge_ports enp1s0
bridge_fd 0
bridge_maxwait 0
bridge_stp off
/etc/default/lxc-net
USE_LXC_BRIDGE="true"
LXC_DHCP_RANGE="192.168.1.161,192.168.1.250"
LXC_ADDR="192.168.1.161"
LXC_NETMASK="255.255.255.0"
LXC_NETWORK="192.168.1.0/24"
LXC_DHCP_CONFILE=/etc/lxc/dhcp.conf
LXC_BRIDGE="lxcbr0"
the result of the ifconfig is
lxcbr0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.160 netmask 255.255.255.0 broadcast 0.0.0.0
the config of my container is
#network config
lxc.net.0.type = veth
lxc.net.0.flags = up
lxc.net.0.link = lxcbr0
lxc.net.0.hwaddr = 70:85:c2:8a:00:ef
lxc.net.0.ipv4.address = 192.168.1.163
lxc.net.0.ipv4.gateway = 192.168.1.1
lxc.sysctl.net.ipv6.conf.eth0.disable_ipv6=1
lxc.sysctl.net.ipv6.conf.all.disable_ipv6=1
What is wrong, where is my mistake?
Thanks