[Bug 964882] [NEW] Static IPv6 configuration fails in lxc guests because of readonly /proc/sys

Launchpad Bug Tracker 964882 at bugs.launchpad.net
Wed Mar 28 04:01:29 UTC 2012


You have been subscribed to a public bug:

This is a complex issue, libvirt driver for lxc sets /proc and /proc/sys
as readonly which can be seen as a good thing, however ifup wants to set
sysctl net.ipv6.conf.eth0.autoconf=0 which fails and ifup exits early
failing to set the ip address of the interface.

STR:

1. Create a precise VM using lxc-create
2. Inside the rootfs, modify the /etc/network/interfaces to read something like:
```
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
    address 192.168.1.20
    netmask 255.255.255.0
    network 192.168.1.0
    broadcast 192.168.1.255
    gateway 192.168.1.1

iface eth0 inet6 static
    address 2a01:d0:801a::2:1
    netmask 64
    gateway 2a01:d0:801a::1
```
Feel free to change the address/gateway - those are used by my machines now.

3. Boot the container.

Expected results:
IPv6 address is assigned.

Actual results:
There is no IPv6 address assigned.
Attempting to ifdown eth0 fails because it is seen as not configured, ifup eth0 fails right after configuring the ipv4 connection, when it disables autoconfiguration using sysctl.

One can work around this using a terrible hack of replacing sysctl with
some sort of script or binary that returns successfully on every
request.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: libvirt-bin 0.9.8-2ubuntu14
ProcVersionSignature: Ubuntu 3.2.0-20.32-generic 3.2.12
Uname: Linux 3.2.0-20-generic x86_64
ApportVersion: 1.95-0ubuntu1
Architecture: amd64
Date: Mon Mar 26 02:56:35 2012
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Alpha amd64 (20120225)
SourcePackage: libvirt
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: ifupdown (Ubuntu)
     Importance: Undecided
         Status: New

** Affects: libvirt (Ubuntu)
     Importance: Medium
         Status: Confirmed


** Tags: amd64 apport-bug precise
-- 
Static IPv6 configuration fails in lxc guests because of readonly /proc/sys
https://bugs.launchpad.net/bugs/964882
You received this bug notification because you are a member of Ubuntu Foundations Bugs, which is subscribed to ifupdown in Ubuntu.




More information about the foundations-bugs mailing list