Failed to obtain the IP address for 'docker' (beta 9)

Expected behavior

The container to start and work properly.

Actual behavior

Failed to obtain the IP address for ‘docker’; the DNS service may not be able to resolve it: Name or service not known.

Information

I’m using beta 9 (on mac os x 10.11.4) and when I try to start the mesos-master docker container I get the error described above.

pinata diagnose -u:

OS X: version 10.11.4 (build: 15E65)
Docker.app: version v1.11.0-beta9
Running diagnostic tests:
[OK]      docker-cli
[OK]      Moby booted
[OK]      driver.amd64-linux
[OK]      vmnetd
[OK]      osxfs
[OK]      db
[OK]      slirp
[OK]      menubar
[OK]      environment
[OK]      Docker

Steps to reproduce the behavior

  1. Following the directions from the github page (linked above), start the mesos-master container:
docker run -d --net=host \
  -e MESOS_PORT=5050 \
  -e MESOS_ZK=zk://127.0.0.1:2181/mesos \
  -e MESOS_QUORUM=1 \
  -e MESOS_REGISTRY=in_memory \
  -e MESOS_LOG_DIR=/var/log/mesos \
  -e MESOS_WORK_DIR=/var/tmp/mesos \
  -v "$(pwd)/log/mesos:/var/log/mesos" \
  -v "$(pwd)/tmp/mesos:/var/tmp/mesos" \
  mesosphere/mesos-master:0.28.0-2.0.16.ubuntu1404

In beta 8 I would set MESOS_HOSTNAME and MESOS_HOST to be equal to the IP address of the docker container, which I retrieved by pinging docker.local:

$(ping -c 1 docker.local | grep "^PING docker.local" | gawk '{print $3}' | tr -d '(' | tr -d ')' | tr -d ':')

But that no longer works.

1 Like