Linux Containers (LXC) is a userspace interface for operating system-level virtualization features in the mainline Linux kernel, such as kernel namespaces and control groups (cgroups). These allow multiple distinct user space instances to be run on a single kernel.

learn more… | top users | synonyms

0
votes
1answer
12 views

How can I reuse the Ansible inventory for local tasks?

I'm trying to make use of Ansible for configuration management and centralized administration. All the machines I'm interested about are actually containers on the host which is going to run Ansible. ...
1
vote
0answers
16 views

What is the correct way to start a container with a given command?

I want to create a set of containers for simulating network traffic. Inside each of the containers, I would like to set a different network delay. Right now I am doing it manually using this command, ...
0
votes
0answers
18 views

Is possible to have full guest system under host installed via DebootstrapChroot?

My goal is installing Ubuntu 14.04.2 LTS under Debian 7 wheezy with full GNOME Desktop. I know I can use use tools like VirtualBox etc. but it seems like overhead. To be more precise under this Ubuntu ...
0
votes
0answers
6 views

How can I list all connections to my host, including those to LXC guests?

I tried both netstat and lsof, but it appears it's not possible to see the connections to my LXC guests. Is there a way to achieve this ... for all guests at once? Essentially what throws me off ...
1
vote
0answers
5 views

How would I get the preprocessed configuration of an LXC guest?

So LXC is installed, guests configured and working, but how would I extract information from the effective LXC configuration of a single guest? Now the naive approach is obvious. Take the output of ...
1
vote
0answers
11 views

A way to set parameters in the LXC parent cgroups

So I have LXC installed, guest containers configured and all. The LXC containers each go into their own submodule (in cgroup parlance) and each are configured with cpu.shares and also the memory ...
1
vote
1answer
35 views

Can't connect to the sshd in my unprivileged LXC guest. What to do?

So you configured your unprivileged LXC guest, by defining lxc.id_map = u 0 1000000000 10000 lxc.id_map = g 0 1000000000 10000 and of course assigning those subordinate UID/GID ranges to an ...
0
votes
0answers
32 views

How to install graphic capabilities to CoreOs?

I would like to install CoreOs as a base on my desktop machine. Then, I could launch some containers, with eventualy a graphical environnement. So I have to add all the graphic stack: GPU drivers, ...
2
votes
1answer
56 views

LXC external IP configuration for containers

I rent a dedicated server and want to use LXC instead of KVM. I want to buy IPs for every single container. For now i have two external IPs: 193.X.X.30/32 213.X.X.31/32 I prefer a routing solution ...
0
votes
0answers
9 views

How to create a module that can maintain containers for applications? [migrated]

I am trying to implement a module for the kernel that implements page coloring. And now I want to add new features that assign some colors to N linux containers. My question is whether it is possible ...
0
votes
1answer
26 views

Can I use LXC library in my c program?

Currently, I am designing a c program that will create multiple container and put different applications into them separately to achieve isolation. Is it possible to leverage LXC library to it? I ...
0
votes
1answer
74 views

How to ssh between lxc containers

I have an Ubuntu host running Ubuntu lxc containers. Whenever I try to ssh between containers, I get: root@master02:~# ssh root@slave01 -vvv OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014 debug1: Reading ...
1
vote
0answers
24 views

Linux Container LXC Intra Host Networking Issues

I have a problem that I cannot seem to resolve. I have two hosts M and N. A container in host M can ping the gateway, its host and all containers in Host N but cannot ping any co-hosted container in ...
0
votes
0answers
57 views

Virtualization on Intel Edison

I want to do virtualization on the Edison. (Edison has vt-x.) On Yocto linux there isn't anything in the repo that is useful. On Ubilinux there is KVM but there is no kernel module in aptitude package ...
2
votes
2answers
46 views

Making Ubuntu programs available to fedora through “chroot”

I have Fedora and Ubuntu installed on different partitions on my system. Now i want to make programs such as "adobe reader" or "kerio-control-vpnclient-8.4.2-2869-linux" available to fedora. those ...
0
votes
0answers
45 views

how to mount samba dir into lxc container

I want to have access to samba dir inside lxc container. I found, that i can't mount directly, but have to mount samba to host, than use bind mount in container's config. I add ...
1
vote
1answer
351 views

docker - how to run x desktop in a container?

I'm trying to set up my Linux machine to run multiple guest OSes, one of those being a Windows VM, and another a Linux container. The goal here is to prevent me from messing up the host system, while ...
2
votes
1answer
240 views

Installing MongoDB in Ubuntu LXC Container. Fails with 'invoke-rc.d: initscript mongod, action “start” failed.'

I can't manage to install mongodb in a Ubuntu LXC container. I've set-up the Ubuntu 14.10 host by following these instructions: https://linuxcontainers.org/lxc/getting-started/ lxc-create --version ...
2
votes
1answer
96 views

Moving LXC container's backing storage

I have a bunch of LXC containers running on a machine. All of them have their rootfs in the default location /var/lib/lxc/*/rootfs. This directory lives on a rather small partition on the host. I have ...
0
votes
0answers
19 views

How do I edit files in LXC?

I have a Centos 6.6 running on lxc. I would like to edit files using Sublime or Gedit but not as a root user. Presently I do a gksudo editor and then open rootfs folder. Is there a better way of doing ...
1
vote
0answers
72 views

Setup public IP address on LXC container

Can anyone tell me how to setup a network interface for each LXC container so that each container can have its own dedicated IP address? Here's what the /etc/network/interfaces file on my host node ...
0
votes
0answers
43 views

Do I need systemd-logind service on server?

I'm setting up debian 8 lxc container on debian 8. And I see a lot of: [FAILED] Failed to start Login Service. See 'systemctl status systemd-logind.service' for details. when the container starts. ...
1
vote
1answer
116 views

How to make a local template for a linux container and point to that

I am a newbie to the world of Linux Containers. I looked at quite a few webpages, wikipedia and checked out the questions at stackexchange but without any answers. Maybe my 'keyword fu' is not strong ...
0
votes
1answer
131 views

Installing Java JDK in busybox in an LXC container - java/lang/NoClassDefFoundError: java/lang/Object

In a web application I'm developing, users will be able to upload java code and I will need to compile and run that. For security reasons, I'd like to that inside an LXC container, and for footprint ...
1
vote
0answers
77 views

Shorewall on router keeps blocking apt-get update on virtual guest

I have a dual-IP LXC server with several unprivileged containers configured for three users. Each user has his own bridge: lxcbr0, lxcbr1 and lxcbr2. For efficiency, the host runs apt-cacher-ng. Each ...
1
vote
1answer
31 views

Snapshotting a Linux container in Debian

I know that the command $ lxc-snapshot exists somewhere, but it seems that it's not available on Debian? Forgive my Linux ignorance - but how do I get a hold of this capability? Is there an ...
11
votes
3answers
541 views

What are benefits and downsides of unprivileged containers?

The technical explanation of what is unprivileged container is quite good. However, it is not for ordinary PC user. Is there a simple answer when and why people should use unpriviliged containers, and ...
1
vote
3answers
495 views

“failed to attach 'veth87VSIJ' to the bridge 'virbr0': No such device”

I am using Fedora 20 in a VM and trying to learn to use containers. I have created a container but can't start it. Here is the terminal output: [root@localhost home]# lxc-start -n test lxc-start: ...
1
vote
0answers
25 views

Debian - System (audio) Settings breaking when starting/stopping LXC

I'm rather new to Linux, recently having to start using it to make something for work (controlling Linux Containers). I'm on debian: $ uname -a Linux debian 3.2.0-4-amd64 #1 SMP Debian ...
8
votes
1answer
254 views

What is an unprivileged LXC container?

What does it mean if a Linux container (LXC container) is called "unprivileged"?
4
votes
1answer
850 views

userns container fails to start, how to track down the reason?

When creating a userns (unprivileged) LXC container on Ubuntu 14.04 with the following command line: lxc-create -n test1 -t download -- -d $(lsb_release -si|tr 'A-Z' 'a-z') -r $(lsb_release -sc) -a ...
0
votes
1answer
176 views

How can i add network interface to LXC Container

I have a question about Network Interfaces in LXC container: In my container,I have by default these interfaces: ubuntu@u5:~$ ifconfig eth0 Link encap:Ethernet HWaddr 00:16:3e:b7:de:91 ...
1
vote
0answers
63 views

Subordinate GIDs/UIDs with LXC and userns for unprivileged user?

When using userns (via LXC in my case), you assign a range of subordinate GIDs and UIDs to an unprivileged user. See for resources: subuid(5), subgid(5), newuidmap(1), newgidmap(1), ...
3
votes
0answers
702 views

How to setup unprivileged LXC container without reboot?

I am writing some bootstrapping scripts, and I can't get usermode LXC containers working on vanilla Ubuntu 14.04 headless without a reboot. Here is what i do. First, I download and install Ubuntu ...
0
votes
0answers
58 views

How can I assign an elastic ip to a container running in ubuntu on AWS?

I have been trying to find a way to have multiple servers running on one ec2 instance with each server having a public static ip addresses. I haven't found anything that would help me solve this ...
4
votes
2answers
833 views

How to create user cgroups with systemd

I use unprivileged lxc containers in Arch Linux. Here are the basic system infos: [chb@conventiont ~]$ uname -a Linux conventiont 3.17.4-Chb #1 SMP PREEMPT Fri Nov 28 12:39:54 UTC 2014 x86_64 ...
3
votes
2answers
495 views

What is a Linux container and a Linux hypervisor?

I looked at the stackexchange site but couldn't find anything. I looked at the wikipedia entry on Linux container https://en.wikipedia.org/wiki/LXC and as well as hypervisor ...
0
votes
1answer
70 views

Could I install both Docker and LXC on the same linux box?

Docker and LXC both has it pros and cons. For instance, LXC could run properly with traditional init service or process but docker couldn't (at this moment).
1
vote
0answers
51 views

Dedicate USB hardware to LXC container

Reading the LXC documentation, it seems possible to dedicate the physical network port eth2 to an LXC container with config something like: lxc.network.type = phys lxc.network.link = eth2 I'm ...
1
vote
1answer
59 views

How do I conserve the userns UID/GID mappings when archiving an LXC guest?

I'd like to archive an existing LXC container that has been configured to run as unprivileged LXC container (see this question). How can I conserve all the file system meta-data that is used to store ...
2
votes
2answers
806 views

lxc-start: No cgroup mounted on the system

Trying to start a Linux container, I get the following: lxc-start: No cgroup mounted on the system OS is Debian 7.
5
votes
1answer
274 views

Migrate an unprivileged LXC container between users

I have an Ubuntu 14.04 server installation which acts as an LXC host. It has two users: user1 and user2. user1 owns an unprivileged LXC container, which uses a directory (inside ...
10
votes
1answer
428 views

Linux: Is there handy way to exec a program binding it to IP-address of choice?

In FreeBSD 4.9 it was very easy to accomplish with just a single command like jail [-u username] path hostname ip-number command if path was / you had running just the same program as usual but ...
0
votes
3answers
386 views

No qemu-debootstrap in Arch Linux

I just installed lxc in Arch Linux, but the qemu-debootstrap binary seems missing, This command sudo lxc-create -n test -t ubuntu -P /run/shm/1 complains about that. I couldn't find it with either ...
0
votes
0answers
547 views

Can a process running in a linux container communicate with another process running on the host OS via IPC?

I have 2 processes A and B. Currently, both A and B are running on the same OS (RHEL6.2) and the processes can intercommunicate via TCP sockets. My objective is to run process B in a Linux Container ...
0
votes
1answer
78 views

How root can make sure that this time sudo will not prompt for password a specific user?

I am writing a script, that will setup lxc on the host, and then configure a container. I want this script to be unattended. After the container is created and run, there is a moment, when I want to ...
12
votes
1answer
3k views

What makes systemd-nspawn still “unsuitable for secure container setups”?

This is stated in the man page for systemd-nspawn Note that even though these security precautions are taken systemd-nspawn is not suitable for secure container setups. Many of the security ...
1
vote
2answers
337 views

Do all Linux processes write EOF to stdout when they are terminating/have finished terminating?

I'm having trouble with sending shutdown -h 0 to a lxc Debian container (i.e. executing this command in the lxc) with with the python pexpect module (in a python script). In this module the user can ...
0
votes
0answers
2k views

Unable to mount cgroup

I've been searching for a solution to this problem but none was working. I would like to start my LXC container but i need to mount cgroup before. [root@stag-devCentOs ~]# lxc-start -n debianLxc ...
3
votes
1answer
2k views

USB passthrough for LXC containers

PROBLEM: So I've been trying to get a usb device (primesense - the OEM reference for the Kinect) to passthrough to an LXC container so I can develop without worrying about polluting my stable system ...