lxc

How to run docker LXC containers on another partition? [closed]

非 Y 不嫁゛ 提交于 2019-12-07 03:54:01
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . My system has two partitions: 5G main partition where Ubuntu is installed 100G side partition at /mnt/eda that I'd like to use for Docker container runs I need to start multiple Docker containers that will take up >10G additional disk space after they're launched. I want them to use disk space form /mnt/eda ,

what will be impacted for compiling code in different kernel in docker?

China☆狼群 提交于 2019-12-06 05:56:07
问题 Can I trust the builds in docker container for redhat6.4 in Ubuntu 14.04 host for c/c++ source codes ? or any limitation I need to consider ? We are trying to use docker to serve different OS platform to compile the source codes, since technology in docker is share the host os's kernel, see related question What is the relationship between the docker host OS and the container base image OS? My host OS is ubuntu 14.04 (easy to install docker), kernel is 3.13.0-24-generic My application

Not able to connect to docker containers using SSH [closed]

我们两清 提交于 2019-12-06 04:30:36
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 3 years ago . I am new to Docker, I built the container from a Dockerfile, and I can see the container creating and running, but I am not able to connect to that container using ssh. Here is my Dockerfile: FROM ubuntu:12.04 RUN apt-get update RUN apt-get install -y apache2 & openssh-server ENV APACHE_RUN_USER www-data ENV

Moving docker root folder to a new drive / partition

半世苍凉 提交于 2019-12-06 04:17:10
问题 I am trying to move the "/var/lib/docker" folder from one disk to another since that is taking up too much space. I keep running into some errors relating to permissions! According to these questions: How do I move a docker container's image to a persistent disk? How to run docker LXC containers on another partition? My disk is mounted on "/data" and I copied the "/var/lib/docker" folder to "/data/docker" This is what I tried: Tried out the -g flag from DOCKER_OPTS with "/data/docker" Tried

LXC with Open vSwitch

亡梦爱人 提交于 2019-12-06 03:48:31
问题 I want to try OVS (software Linux switch) http://openvswitch.org/ with my LXC container with Ubuntu as host and guest. So I have installed it: # apt-get install openvswitch-switch Configured according this doc https://infologs.wordpress.com/2015/06/19/how-to-attach-lxc-container-to-ovs-openvswitch/ Created test container: # lxc-create -t ubuntu -n veth03-ovs -- -r trusty Created ovs bridge and assigned IP to it: # ovs-vsctl add-br switch0 # ip add add 192.168.100.1/24 dev switch0 Let it be

LXC简介及通过LXC在CentOS上构建单机集群

放肆的年华 提交于 2019-12-06 01:39:57
LXC介绍 linux container(LXC)就是一种操作系统级的虚拟化技术。是基于Linux操作系统的虚拟化技术,翻译为linux 容器。它可以提供轻量级的虚拟化,以便隔离进程和资源,而且不需要提供指令解释机制以及全虚拟化的其他复杂性。 容器有效地将由单个操作系统管理的资源划分到孤立的组中,以更好地在孤立的组之间平衡有冲突的资源使用需求。与虚拟化相比,这样既不需要指令级模拟,也不需要即时编译。容器可以在核心 CPU 本地运行指令,而不需要任何专门的解释机制。此外,也避免了半虚拟化和系统调用替换中的复杂性。通过提供一种创建和进入容器的方式,操作系统让应用程序就像在独立的机器上运行一样,但又能共享很多底层的资源。例如,可以有效地共享公共文件(比如 glibc)的页缓存,因为所有容器都使用相同的内核,而且所有容器还常常共享相同的 libc 库(取决于容器配置)。这种共享常常可以扩展到目录中其他不需要写入内容的文件。 容器在提供隔离的同时,还通过共享这些资源节省开销,这意味着容器比真正的虚拟化的开销要小得多。Linux Container提供了在单一可控主机节点上支持多个相互隔离的server container同时执行,Linux Container有点像chroot,提供了一个拥有自己进程和网络空间的虚拟环境。LXC 通过利用内核的CGroup来提供用户空间的对象

Where are core files stored in a lxc container?

放肆的年华 提交于 2019-12-05 19:38:24
When I am running code on a container it cores I am not able to locate it on my container(or the core file is not being stored). ulimit -c is set to unlimited /proc/sys/kernel/core_pattern is set to |/usr/share/apport/apport %p %s %c %P (what is the meaning of | ?) Do I need to make any changes in/to the host system? | indicates that a program should handle the core dump. Rather than saving the coredump to a file it will be piped into that programs input. Means if core_pattern is set to |... apport apport will handle the core dumps. Unfortunately apport will create coredumps only for installed

Starting Xserver in Docker Ubuntu container

坚强是说给别人听的谎言 提交于 2019-12-05 16:33:57
I have minimal Ubuntu installation in my container and I want to have Xserver running. I need XServer, because my app requires meshlabserver, which itself needs Xserver. I installed xserver-xorg and all other packages, but when I try to start X in container via /usr/bin/X :0 it says: Fatal server error: (EE) xf86OpenConsole: Cannot open /dev/tty0 (No such file or directory) What am I doing wrong? How do I start X server? UPDATE: related question: Host screen turns off when I start X server in docker container In my case it works nicely when I start container in privileged mode: docker run -

How to run docker LXC containers on another partition? [closed]

折月煮酒 提交于 2019-12-05 06:01:24
My system has two partitions: 5G main partition where Ubuntu is installed 100G side partition at /mnt/eda that I'd like to use for Docker container runs I need to start multiple Docker containers that will take up >10G additional disk space after they're launched. I want them to use disk space form /mnt/eda , but how do I do that? Currently, whenever I import or run a container, space from my main partition is taken up. I tried downloading the binary and starting it from the side partition, but space from main partition was still being used up. I can't attach/mount drives to my containers --

How does Docker share resources

喜夏-厌秋 提交于 2019-12-05 05:44:18
I've been looking into Docker and I understand from this post that running multiple docker containers is meant to be fast because they share kernel level resources through the "LXC Host," however, I haven't found any documentation about how this relationship works that is specific to the docker configuration, and at what level are resources shared. What's the involvement of the Docker image and the Docker container with shared resources and how are resources shared? Edit: When talking about "the kernel" where resources are shared, which kernel is this? Does it refer to the host O.S (the level