weaveworks / weave

Simple, resilient multi-host containers networking and more.
https://www.weave.works
Apache License 2.0
6.62k stars 670 forks source link

Docker error on 'weave stop' when $DOCKER_HOST is set #1575

Open bboreham opened 9 years ago

bboreham commented 9 years ago
$ ./weave stop
WARNING: It appears that your environment is configured to use the Weave Docker API proxy. Stopping it will break this and subsequent docker invocations. To restore your environment, run 'eval $(weave env --restore)'.
Error deleting container: Cannot connect to the Docker daemon. Is 'docker -d' running on this host?
Cannot connect to the Docker daemon. Is 'docker -d' running on this host?

The "Error deleting container" arises from the weave script being invoked via docker run --rm in exec_remote(). However, removing that argument does not make things much better:

Post http:///var/run/weave/weave.sock/v1.19/containers/54c0dacad1096524db5dd3077a91ac534ada6dfe5dbf7c6d3c66ebc49536e2ed/wait: write unix /var/run/weave/weave.sock: broken pipe. Are you trying to connect to a TLS-enabled daemon without TLS?

Maybe we should adjust the "will break this" message to make it clear we expect an angry message right away.

inercia commented 9 years ago

This error message is produced by something we are doing, it can be confusing and it has no real value for users, so I think the best thing we could do is to silence the Docker message... I think that adding more text to the WARNING:... will make things even more confusing.

bboreham commented 9 years ago

I don't see how we can silence the annoying message without also silencing any potentially useful messages from the inner weave script.

Maybe re-implementing weave stop at the outer level, stopping the proxy last, would work, but it is a lot of effort.

macduff23 commented 4 years ago

I just turned up 3 ubuntu disco boxes - multi-exec'd the commands identical on all 3 nodes during the install. received this error when stopping weave to restart and peer all 3, however only 2 gave me the error. "root@shinto:/# weave stop WARNING: It appears that your environment is configured to use the Weave Docker API proxy. Stopping it will break this and subsequent docker invocations. To restore your environment, run 'eval $(weave env --restore)'. ERRO[0001] error waiting for container: unexpected EOF" Thats the daddy .. so is this an issue or no? Looks like yes... root@shinto:/# weave launch 192.168.1.50 192.168.1.100 192.168.1.150 Cannot connect to the Docker daemon at unix:///var/run/weave/weave.sock. Is the docker daemon running?" - Hmmmm host 1/3 has no issue. interesting? ( <3 weave though been using it for a while)

This is an older post i see is there a resolution at this time? this is a totally fresh setup not sure why one would be working and 2 not. Thanks

bboreham commented 4 years ago

Please open a new issue; yours does not add to this one which is about the wording of a message.