I'm running LXC container (lxc 0.7.2-1) on Debian squeeze with bridge networking configured by the book with public IP and I have problem that it exposes fake MAC address from LXC container to external network where it gets blocked by switch port security so preventing LXC container from communicating with the world. I run another LXC container on Ubuntu 12.04.2 LTS (lxc 0.7.5-3ubuntu67) with same network configuration but I don't have any problems as it doesn't expose fake MACs to external network and all communications goes with host's MAC.
Currently I'm trying to find difference in network configuration between hosts but without much success. Could it be possibly version dependent behavior of lxc itself?
Debian /etc/network/interfaces
auto br0
iface br0 inet static
bridge_ports eth0
bridge_fd 0
bridge_stp off
bridge_maxwait 0
address y.y.y.9
netmask 255.255.255.192
broadcast y.y.y.63
gateway y.y.y.1
pre-up iptables-restore < /etc/iptables.up.rules
Debian LXC network config
lxc.network.type = veth
lxc.network.flags = up
lxc.network.link = br0
lxc.network.hwaddr = fe:95:57:4b:b4:9b
lxc.network.ipv4 = y.y.y.12/26
Ubuntu /etc/network/interfaces
auto br0
iface br0 inet static
bridge_ports eth0
bridge_fd 0
bridge_stp off
bridge_maxwait 0
address z.z.z.146
netmask 255.255.255.0
broadcast z.z.z.255
gateway z.z.z.1
pre-up iptables-restore < /etc/iptables.rules
up route add x.x.x.1 br0
Ubuntu LXC network config
lxc.network.type = veth
lxc.network.flags = up
lxc.network.link = br0
lxc.network.name = eth0
lxc.network.ipv4 = x.x.x.1/32
lxc.network.hwaddr = 00:16:3e:87:b5:b9