[lxc-devel] [lxc/lxc] 0080be: c/r: put lxc-restore-net in /usr/share

GitHub noreply at github.com
Mon Oct 27 21:44:21 UTC 2014


  Branch: refs/heads/master
  Home:   https://github.com/lxc/lxc
  Commit: 0080bebf3195a4a4f4868d89224e07658a1fccca
      https://github.com/lxc/lxc/commit/0080bebf3195a4a4f4868d89224e07658a1fccca
  Author: Tycho Andersen <tycho.andersen at canonical.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M configure.ac
    M src/lxc/Makefile.am
    M src/lxc/lxccontainer.c

  Log Message:
  -----------
  c/r: put lxc-restore-net in /usr/share

On restore, we pass criu a script to manage the network interfaces (i.e. the
full path to lxc-restore-net), which we previously installed into
/var/lib/<tuple>/lxc. However, this is also the directory that is the default
for use in mounting the rootfs locally before pivot_root()ing. So, we mounted
the rootfs and then happliy called criu, pointing it to this directory which
didn't have lxc-restore-net any more, it just had the container's rootfs.
Instead, we should put lxc-restore-net somewhere else, so that criu can still
see it after the rootfs is mounted.

Signed-off-by: Tycho Andersen <tycho.andersen at canonical.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>


  Commit: 6a0c909a375a75e005b2048b2d143320678e11b9
      https://github.com/lxc/lxc/commit/6a0c909a375a75e005b2048b2d143320678e11b9
  Author: Serge Hallyn <serge.hallyn at ubuntu.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M src/lxc/conf.c
    M src/lxc/conf.h
    M src/lxc/start.c

  Log Message:
  -----------
  lxc-start: don't re-try to mount rootfs if we already did so

If we are root using a user namespace and are mounting a blockdev as rootfs,
then we do this before unsharing the userns, because we are not allowed to
do it in a userns.  But after unsharing the userns, we unconditionally
retried mounting the rootfs, resulting in failure.  stop that.

Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: 48921d92b597a8560f8392ff7981f9f233295b35
      https://github.com/lxc/lxc/commit/48921d92b597a8560f8392ff7981f9f233295b35
  Author: Serge Hallyn <serge.hallyn at ubuntu.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M src/lxc/utils.c

  Log Message:
  -----------
  lxc_global_config_value: simplify the theme

Rather than try to free all the not-being-returned items at
each if clause where we assign one to return value, just NULL
the one we are returning so we can safely free all the
values.  This should fix the newly reported coverity memory
leak

Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: cfa70b8824e3830482864f97e195f60c12ad9098
      https://github.com/lxc/lxc/commit/cfa70b8824e3830482864f97e195f60c12ad9098
  Author: Serge Hallyn <serge.hallyn at ubuntu.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M src/lxc/attach.c

  Log Message:
  -----------
  attach: don't use confstr(_CS_PATH)

It is not system-definable, rather glibc sets that to bin:/usr/bin, which is
simply too restrictive.  So just always set our preferred path.

This was reported at:
https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/1384327

Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: edf77341a57a81d8a5c9b9a767d8ba79f26ba8c4
      https://github.com/lxc/lxc/commit/edf77341a57a81d8a5c9b9a767d8ba79f26ba8c4
  Author: Serge Hallyn <serge.hallyn at ubuntu.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M src/lxc/bdev.c

  Log Message:
  -----------
  overlay and aufs clone_paths: be more robust

Currently when we clone a container, bdev_copy passes NULL as dst argument
of bdev_init, then sees bdev->dest (as a result) is NULL, and sets
bdev->dest to $lxcpath/$name/rootfs.  so $ops->clone_paths() can
assume that "/rootfs" is at the end of the path.  The overlayfs and
aufs clonepaths do assume that and index to endofstring-6 and append
delta0.  Let's be more robust by actually finding the last / in
the path.

Then, instead of always setting oldbdev->dest to $lxcpath/$name/rootfs,
set it to oldbdev->src.  Else dir_clonepaths fails when mounting src
onto dest bc dest does not exist.  We could also fix that by creating
bdev->dest if needed, but that addes an empty directory to the old
container.

This fixes 'lxc-clone -o x1 -n x2' if x1 has lxc.rootfs = /var/lib/lxc/x1/x
and makes the overlayfs and aufs paths less fragile should something else
change.

Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: df7216f664570dd6fb4b013e7aef802ac47da2af
      https://github.com/lxc/lxc/commit/df7216f664570dd6fb4b013e7aef802ac47da2af
  Author: Simon Deziel <simon.deziel at gmail.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M templates/lxc-ubuntu.in

  Log Message:
  -----------
  Create the apt proxy in the cache instead of the 1st container

This addresses https://github.com/lxc/lxc/issues/280.

Signed-off-by: Simon Deziel <simon at sdeziel.info>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: 9eaf8a596eb8e522eb18d7f5dfafd5e96499323b
      https://github.com/lxc/lxc/commit/9eaf8a596eb8e522eb18d7f5dfafd5e96499323b
  Author: Sergio Jimenez <tripledes at gmail.com>
  Date:   2014-10-27 (Mon, 27 Oct 2014)

  Changed paths:
    M src/lxc/conf.c
    M src/lxc/confile.c
    M src/tests/get_item.c

  Log Message:
  -----------
  Fixed mismatch on ipvX gateway

Signed-off-by: Sergio Jimenez <tripledes at gmail.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>


Compare: https://github.com/lxc/lxc/compare/bf1e86368272...9eaf8a596eb8


More information about the lxc-devel mailing list