[pkg-lxc-devel] Bug#883163: lxc.network.0.link configuration value is ignored

Harald Dunkel harri at afaics.de
Fri Aug 10 05:26:45 BST 2018


Hi Salvador,

using lxc 2.0.9 the config lines to define 2 network interfaces look
like this:

## Network eth0
lxc.network.type                        = veth
lxc.network.hwaddr                      = 00:20:6f:dd:b4:a0
lxc.network.flags                       = up
lxc.network.link                        = br5
lxc.network.name                        = eth0
# lxc.network.ipv4                      = 5.xxx.yyy.zzz/26
# lxc.network.ipv4.gateway              = 5.xxx.yyy.1
# lxc.network.ipv6                      = 2001:db8:30:ffe0::e4/64
# lxc.network.ipv6.gateway              = 2001:db8:30:ffe0::1

## Network eth1
lxc.network.type                        = veth
lxc.network.hwaddr                      = 00:20:23:ee:dc:1b
lxc.network.flags                       = up
lxc.network.link                        = br4
lxc.network.name                        = eth1
lxc.network.ipv4                        = 10.1.1.228/24


The line with "lxc.network.type" marks the start of a new block.
For lxc3 (not in Debian yet) this has been improved:

## Network eth0
lxc.net.0.type                        = veth
lxc.net.0.hwaddr                      = 00:20:6f:dd:b4:a0
lxc.net.0.flags                       = up
lxc.net.0.link                        = br5
lxc.net.0.name                        = eth0
# lxc.net.0.ipv4                      = 5.xxx.yyy.zzz/26
# lxc.net.0.ipv4.gateway              = 5.xxx.yyy.1
# lxc.net.0.ipv6                      = 2001:db8:30:ffe0::e4/64
# lxc.net.0.ipv6.gateway              = 2001:db8:30:ffe0::1

## Network eth1
lxc.net.1.type                        = veth
lxc.net.1.hwaddr                      = 00:20:23:ee:dc:1b
lxc.net.1.flags                       = up
lxc.net.1.link                        = br4
lxc.net.1.name                        = eth1
lxc.net.1.ipv4                        = 10.1.1.228/24


Hope this helps
Harri



More information about the Pkg-lxc-devel mailing list