[lxc-devel] [PATCH] lxc-busybox: remove unnecessary bind-mount

2013-12-06 Thread Bogdan Purcareata
Since the line immediately following will mount the entire /sys read-only, hence /sys/kernel/security too. Also, when installing the container template on systems with no securityfs support, starting the container will fail. Signed-off-by: Bogdan Purcareata --- templates/lxc-busybox.in | 1

Re: [lxc-devel] [PATCH] setup_netdev: re-read ifindex in LXC_NET_PHYS case

2013-11-14 Thread Bogdan Purcareata
gt; case > > Quoting Bogdan Purcareata (bogdan.purcare...@freescale.com): > > When moving an interface from the host netns to a container's, > > the ifindex might not remain the same. This happens when the > > index of the host interface is already assigned to another int

[lxc-devel] [PATCH] setup_netdev: re-read ifindex in LXC_NET_PHYS case

2013-11-14 Thread Bogdan Purcareata
dex in the host netns is not free in the new netns. The patch forces ifindex re-read for the LXC_NET_PHYS case to update the lxc_netdev structure. Signed-off-by: Bogdan Purcareata --- src/lxc/conf.c | 8 1 file changed, 8 insertions(+) diff --git a/src/lxc/conf.c b/src/lxc/conf.c ind

[lxc-devel] Network interface - netns migration bug

2013-11-13 Thread Bogdan Purcareata
Hello, I've encountered this bug with lxc-0.9.0, using the lxc-phys scenario - assigning a physical interface to a container. In my understanding, this is what happens when a container starts (well, the relevant parts): - the configuration file is parsed into a config structure - the kernel in

[lxc-devel] [PATCH] lxcapi_set_cgroup_item: remove duplicate == 0

2013-07-03 Thread Bogdan Purcareata
Signed-off-by: Bogdan Purcareata --- src/lxc/lxccontainer.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lxc/lxccontainer.c b/src/lxc/lxccontainer.c index 677fa56..4e71fb1 100644 --- a/src/lxc/lxccontainer.c +++ b/src/lxc/lxccontainer.c @@ -1393,7 +1393,7 @@ static

[lxc-devel] [PATCH] tests/startone: wrong set_cgroup_item check

2013-07-02 Thread Bogdan Purcareata
Minor typo. Signed-off-by: Bogdan Purcareata --- src/tests/startone.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tests/startone.c b/src/tests/startone.c index d781e75..2c1f39b 100644 --- a/src/tests/startone.c +++ b/src/tests/startone.c @@ -201,7 +201,7 @@ int

[lxc-devel] [PATCH v2] lxc-busybox: check when bind-mounting host libdirs

2013-05-15 Thread Bogdan Purcareata
The patch removes the behavior of automatically mounting /lib and /usr/lib, since this is duplicated a few lines below. It will also remove the risk of failing when one of these entries are not present on the host - e.g. on a 64bit machine. Signed-off-by: Bogdan Purcareata --- templates/lxc

[lxc-devel] [PATCH] lxc-busybox: check when bind-mounting host libdirs

2013-05-14 Thread Bogdan Purcareata
The patch changes the busybox template behavior to automatically mount /lib and /usr/lib. In case one of these folders does not exist, starting the container will fail. Also, if there are other lib entries on the host - e.g. /usr/lib64 - mount them as well. Signed-off-by: Bogdan Purcareata

[lxc-devel] [PATCH v2] lxc-template: enable chroot + chpasswd functionality for Busybox hosts

2013-04-11 Thread Bogdan Purcareata
his set of operations is contained in a new MOUNT namespace, using the lxc-unshare call. Signed-off-by: Bogdan Purcareata --- templates/lxc-busybox.in | 30 -- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/templates/lxc-busybox.in b/templates/lxc-busybo

[lxc-devel] Enable chroot correct behavior on busybox hosts

2013-04-09 Thread Bogdan Purcareata
When creating busybox containers on a busybox host, chroot requires /lib to be mounted inside the new environment. This patch adds supoort for this requirement, without breaking functionality on other hosts. -- Precog i

[lxc-devel] [PATCH] Enable support for chroot on busybox hosts

2013-04-09 Thread Bogdan Purcareata
Signed-off-by: Bogdan Purcareata --- templates/lxc-busybox.in | 3 +++ 1 file changed, 3 insertions(+) diff --git a/templates/lxc-busybox.in b/templates/lxc-busybox.in index cb425ec..450c5a5 100644 --- a/templates/lxc-busybox.in +++ b/templates/lxc-busybox.in @@ -189,8 +189,11