Skip to content
This repository has been archived by the owner on Aug 14, 2023. It is now read-only.

docker-machine will hang docker daemon #80

Closed
richtong opened this issue May 17, 2016 · 7 comments
Closed

docker-machine will hang docker daemon #80

richtong opened this issue May 17, 2016 · 7 comments
Assignees

Comments

@richtong
Copy link

richtong commented May 17, 2016

Ok the symptom is that with build 0.5.14, this image converted to using /etc/docker/daemon.json for its configuration and /etc/systemd/system/docker.service has a generic /usr/bin/docker start line.

This is because the main docker-machine does not respect the daemon.json logic and will add it's own command line options and by design the daemon will not start. See docker/machine#3062.

Reproduce by:

If you run docker-machine -d generic against this image with docker-machine 0.6 that is in docker for mac, it does not know about daemon.json and instead adds its configuration in the command line of /etc/systemd/system/docker.service.

This is the specific behavior of the docker daemon (see https://docs.docker.com/engine/reference/commandline/daemon/) so right now the -H options in the command line conflict with the fd:// option and overlay is specified in both.

When the command line and the daemon.json exist, docker will refuse to start. As an aside, if you are using Docker for Mac beta, it does not update any of the command line utilities, so you need to install Docker Toolbox for Mac to get the latest or run the latest installation scripts

The fix: document that if you use docker-machine you must remove daemon.json before running docker-machine create

@richtong richtong changed the title Build 0.5.14 corrupted if docker-machine create -d generic run on it Build 0.5.14 daemon.json conflicts with docker-machine -d generic May 17, 2016
@richtong richtong changed the title Build 0.5.14 daemon.json conflicts with docker-machine -d generic Build 0.5.3 and beyonds daemon.json conflicts with docker-machine 0.6 May 17, 2016
@richtong richtong changed the title Build 0.5.3 and beyonds daemon.json conflicts with docker-machine 0.6 Build 0.5.14 version of docker daemon will not start when configured docker-machine 0.6 May 17, 2016
@richtong richtong changed the title Build 0.5.14 version of docker daemon will not start when configured docker-machine 0.6 docker-machine will hang docker daemons on version 0.5.4 or higher May 17, 2016
@StefanScherer
Copy link
Member

Just for the records: With 0.5.4 we introduced Docker 1.11.1,
a VirtualBox machine 1.11.1 also does not contain any daemon.json file.

@richtong richtong changed the title docker-machine will hang docker daemons on version 0.5.4 or higher docker-machine will hang docker daemons on version 0.5.14 or higher May 17, 2016
@richtong richtong changed the title docker-machine will hang docker daemons on version 0.5.14 or higher docker-machine will hang docker daemons on version 0.5.14 May 17, 2016
@richtong
Copy link
Author

Oops fixed the version numbers should say 0.5.14. I know 0.5.2 works for sure.

@richtong
Copy link
Author

richtong commented May 17, 2016

Also wants sure if I should post to this or to docker-hypriot, but apt-get install docker-hypriot is also broken. Still on 1.10 and it fails to install properly with 0.5.14. I haven't had time to investigate, but perhaps you should bump release that. Great work by the way on the rest. Definitely on the bleeding edge!

@richtong richtong changed the title docker-machine will hang docker daemons on version 0.5.14 docker-machine will hang docker daemon May 17, 2016
@StefanScherer
Copy link
Member

@richtong To install docker-hypriot I guess you have to remove the package docker-engine manually. There are no dependencies between these two packages.

@StefanScherer
Copy link
Member

The /etc/docker/daemon.json was introduced in v0.5.5 with commit f09778c

We have to remove it for now to make the default SD image docker-machine compatible. Overlay and local unix socket can be achieved w/o this file as well.

@StefanScherer
Copy link
Member

Instead of removing /et/docker/daemon.json we can just make it empty with only

{
}

This solves the docker-machine problem.

@richtong
Copy link
Author

Thanks I see sounds like the blog needs to deprecate docker-hypriot and use docker-engine instead then. That is way more standard! Nice work testing 0.5.15 now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants