[lxc-users] multiple containers on the same vlan

Genco Yilmaz gencoyilmaz at gmail.com
Mon Jun 15 08:33:14 UTC 2015


Hi,
   When I try to configure two containers which need to be on the same vlan
lxc-start complains as expected. I believe this is an expected error.
Is there any way to link multiple containers without using softbridge+veth
pair
by using network.type vlan? or what is the best practice in this type of
topology?

thanks.


ERROR
======
lxc-start 1434354562.308 ERROR    lxc_conf - conf.c:instantiate_vlan:3120 -
failed to create vlan interface 'vlan4050' on 'eth7' : File exists
      lxc-start 1434354562.308 ERROR    lxc_conf -
conf.c:lxc_create_network:3261 - failed to create netdev
      lxc-start 1434354562.308 ERROR    lxc_start - start.c:lxc_spawn:826 -
failed to create the network



#CONTAINER1
# Network configuration
lxc.network.type = vlan
lxc.network.flags = up
lxc.network.link = eth7
lxc.network.vlan.id = 4050
lxc.network.name = eth0
lxc.network.ipv4 = 10.100.100.12/24
lxc.network.ipv4.gateway = 10.100.100.2


#CONTAINER1
# Network configuration
lxc.network.type = vlan
lxc.network.flags = up
lxc.network.link = eth7
lxc.network.vlan.id = 4050
lxc.network.name = vlan4050
lxc.network.ipv4 = 10.100.100.11/24
lxc.network.ipv4.gateway = 10.100.100.2


root at vhost3:~# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.2 LTS
Release:        14.04
Codename:       trusty
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20150615/b029ac1b/attachment.html>


More information about the lxc-users mailing list