Differences between revisions 1 and 2
Revision 1 as of 2011-12-12 16:12:12
Size: 1748
Editor: ?MarcusOsdoba
Comment: lxc: split main page and possible network configurations into seperate subpages
Revision 2 as of 2011-12-12 22:58:15
Size: 1833
Editor: GeoffSimmons
Comment: Add DefaultTemplate header.
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
#language en
~-[[DebianWiki/EditorGuide#translation|Translation(s)]]: none-~

Translation(s): none

Please find alternative network setups for containers on the LXC mainpage.

In case of bridged or routed network provided by the host, here is an example.

Host device as bridge

  • persisted in host's /etc/network/interfaces

  • the container's veth virtual ethernet interface can share the network link on the physical interface of the host (eth0).

# The primary network interface
#allow-hotplug eth0
#iface eth0 inet dhcp

auto br0
iface br0 inet dhcp
        bridge_ports eth0
        bridge_fd 0
        bridge_maxwait 0

# uncomment the below and comment the above for static ip setup on the host
#iface br0 inet static
#       bridge_ports eth0
#       bridge_fd 0
#       address <host IP here, e.g.>
#       netmask
#       network <network IP here, e.g.>
#       broadcast <broadcast IP here, e.g.>
#       gateway <gateway IP address here, e.g.>
#       # dns-* options are implemented by the resolvconf package, if installed
#       dns-nameservers <name server IP address here, e.g.>
#       dns-search your.search.domain.here
  • TODO: provide a sample of the network section in the containers config

Additonal bridge device instead of changing a host device to br0

  • setup manually with brctl
  • the container's veth virtual ethernet interface accesses the network via the bridge device created on the host.


  • TODO


  • TODO

References :