[Lxc-users] Questions regarding LXC and nsenter

Ranjib Dey dey.ranjib at gmail.com
Fri Dec 6 17:09:24 UTC 2013


Hi,
Apologies in advance if im asking something stupid.
Im trying to use nsenter with lxc. it works fine with systemd-nspawn based
containers, but not with lxc based containers. Im using ubuntu 14.04 and
nsenter from util-linux 2.24 and lxc 1.0.0alpha3. From whatever i can
search /read in internet, this does not work, but im trying to understand
why. i can see the /proc/CONTAINER_PID/ns/* entries, and if i understand
correctly nsenter uses this information to execute commands. Whats I am not
able to understand is that nsenter executes successfully but inside the
container it shows the host os , with all privileges. i have tried
explicitly specifying the containers rootfs and root directory or working
directory in nsenter, but that does not fixes the problem.

I read couple of mailing list archive on this, and it was recommended not
to use nsenter against lxc. If anyone can explain why this is so (or give
some pointers to resources that can explain this), that will be very
helpful.


thanks in advance

p.s. i have tried the same with fedor19 and lxc 0.9
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20131206/717ab147/attachment.html>


More information about the lxc-users mailing list