Comments (8)
While running docker-in-docker, it's required to mount some missing libs from host to container if you don't want to install them explicitly into the container.
For example, below works for me while using docker compose (I think it's very easy to convert the mounts into raw docker run command)
...
volumes:
- /var/run/docker.sock:/run/docker.sock
- /usr/bin/docker:/usr/bin/docker
- /sys:/sys:ro
- /lib/x86_64-linux-gnu/libsystemd-journal.so.0:/lib/x86_64-linux-gnu/libsystemd-journal.so.0
- /usr/lib/x86_64-linux-gnu/libapparmor.so.1:/usr/lib/x86_64-linux-gnu/libapparmor.so.1
- /lib/x86_64-linux-gnu/libcgmanager.so.0:/lib/x86_64-linux-gnu/libcgmanager.so.0
- /lib/x86_64-linux-gnu/libnih.so.1:/lib/x86_64-linux-gnu/libnih.so.1
- /lib/x86_64-linux-gnu/libnih-dbus.so.1:/lib/x86_64-linux-gnu/libnih-dbus.so.1
- /lib/x86_64-linux-gnu/libgcrypt.so.11:/lib/x86_64-linux-gnu/libgcrypt.so.11
My Env:
$ cat /proc/version
Linux version 3.16.0-30-generic (buildd@kissel) (gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) ) #40~14.04.1-Ubuntu SMP Thu Jan 15 17:43:14 UTC 2015
$ docker -v
Docker version 1.11.0, build 4dc5990
$ docker-compose -v
docker-compose version 1.6.2, build 4d72027
Hope it helps.
from docker-containers.
Running mesos-slave in a docker isn't a particularly recommended operation (Esp. for production), a lot of mesos bits currently program in logic manually manipulating cgroups that can break in subtle ways.
As far as why the docker containerizer isn't working in your case, do you have installed and the daemon running on the host system? That command is mounting in docker from the host system and using it for launching mesos tasks.
from docker-containers.
@mymac80 Have you solved the problem? now i have the same problem, and i have no way not to resolve
from docker-containers.
@mymac80 it doesn't work because you don't have docker installed in your docker container, since you're just using the mesos image it doens't have docker client installed.
You should create a new image based on your mesos image but also have the docker client installed
from docker-containers.
@tnachen Thanks! Will give this a try.
from docker-containers.
@tnachen using
--privileged and -v /var/run/docker.sock:/run/docker.sock -v $(which docker):/bin/docker
seems to be the recommended way to run docker-in-docker. This usually works but for some reason it does not work here.
Seems like some other persons started getting this problem a month ago if you look at comment time stamps: https://hub.docker.com/r/mesosphere/mesos-slave/
from docker-containers.
Hello.
I'm bumping into same issue using mesosphere/mesos-slave:0.28.1
with docker 1.11.1
on 4.5.4-1-ARCH
kernel.
Problem seems to be libsystemd.so.0
when I type docker
inside container image.
root@b127c72e50a5:/# docker
docker: error while loading shared libraries: libsystemd.so.0: cannot open shared object file: No such file or directory
Trusting the cat /etc/issue
output, mesosphere/mesos-slave:0.28.1
seems to be based on Ubuntu 14.04.4 LTS
Here are the missing links for docker
binary which I mounted from my host into /bin of container
root@b127c72e50a5:/# ldd /bin/docker
linux-vdso.so.1 => (0x00007ffce3935000)
libsystemd.so.0 => not found
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f514bf6e000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f514bd69000)
libdevmapper.so.1.02 => not found
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f514b9a4000)
/lib64/ld-linux-x86-64.so.2 (0x000055bd1ddee000)
Maybe this will help a bit
Thanks
from docker-containers.
I think the problem here seems to be that bind mounting the docker.sock is not enough, you need to bind mount the docker client binary as well. However this is fraught with errors since latest versions of docker client are not purely static go binaries, and have dependencies on other shared objects.
The right solution (discussed and proposed by @jieyu ) seems to be to build the Mesos docker containers using the docker in docker build file , but replacing the base image with Ubuntu 14.04 instead of Alpine linux. The resulting image should have the docker client packaged correctly with the Mesos binaries. The Mesos docker container should be able to launch docker containers using the host docker daemon.
from docker-containers.
Related Issues (20)
- mesoscloud Docker images outdated and misconfigured HOT 2
- marahon container don't have web ui HOT 4
- Docker 1.10 issue HOT 2
- Why is mesos-slave-dind not kept up to date? HOT 3
- Missing bind mounts for mesos-slave HOT 7
- SELinux: Could not open policy file HOT 10
- Mesos Master 1.0.0-rc1 docker image fails to start with openssl error HOT 1
- Initial launch instructions are incorrect HOT 4
- Couldnt get Mesos-Slave running, due to DockerContainerizer error HOT 1
- Please downgrade the CLI to an older version HOT 8
- Issue when starting mesos-slave:1.0.11.0.1-2.0.93.ubuntu1404 without mapping to host's docker HOT 2
- Mesos Master/Slave Configuration Links in README Out of Date
- clear
- MESOS_CONTAINERIZERS ERROR HOT 2
- mesos-slave docker image with docker_mesos_image is broken HOT 1
- docker
- Consider removing --privileged argument from agent launch instructions
- Error running mesos-slave
- Latest tag missing
- Local Persistent Volume mount() Silently Fails
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker-containers.