{"action":"created","issue":{"url":"https://api.github.com/repos/docker/docker/issues/26747","repository_url":"https://api.github.com/repos/docker/docker","labels_url":"https://api.github.com/repos/docker/docker/issues/26747/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/26747/comments","events_url":"https://api.github.com/repos/docker/docker/issues/26747/events","html_url":"https://github.com/docker/docker/issues/26747","id":178126473,"number":26747,"title":"Swarm mode DNS lookup resolves only IPs from the same host","user":{"login":"burdiyan","id":1793789,"avatar_url":"https://avatars.githubusercontent.com/u/1793789?v=3","gravatar_id":"","url":"https://api.github.com/users/burdiyan","html_url":"https://github.com/burdiyan","followers_url":"https://api.github.com/users/burdiyan/followers","following_url":"https://api.github.com/users/burdiyan/following{/other_user}","gists_url":"https://api.github.com/users/burdiyan/gists{/gist_id}","starred_url":"https://api.github.com/users/burdiyan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/burdiyan/subscriptions","organizations_url":"https://api.github.com/users/burdiyan/orgs","repos_url":"https://api.github.com/users/burdiyan/repos","events_url":"https://api.github.com/users/burdiyan/events{/privacy}","received_events_url":"https://api.github.com/users/burdiyan/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/docker/docker/labels/area/networking","name":"area/networking","color":"fbca04"},{"url":"https://api.github.com/repos/docker/docker/labels/area/swarm","name":"area/swarm","color":"fbca04"},{"url":"https://api.github.com/repos/docker/docker/labels/kind/bug","name":"kind/bug","color":"FF8C94"},{"url":"https://api.github.com/repos/docker/docker/labels/version/1.12","name":"version/1.12","color":"ededed"}],"state":"closed","locked":false,"assignee":{"login":"mrjana","id":1693482,"avatar_url":"https://avatars.githubusercontent.com/u/1693482?v=3","gravatar_id":"","url":"https://api.github.com/users/mrjana","html_url":"https://github.com/mrjana","followers_url":"https://api.github.com/users/mrjana/followers","following_url":"https://api.github.com/users/mrjana/following{/other_user}","gists_url":"https://api.github.com/users/mrjana/gists{/gist_id}","starred_url":"https://api.github.com/users/mrjana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrjana/subscriptions","organizations_url":"https://api.github.com/users/mrjana/orgs","repos_url":"https://api.github.com/users/mrjana/repos","events_url":"https://api.github.com/users/mrjana/events{/privacy}","received_events_url":"https://api.github.com/users/mrjana/received_events","type":"User","site_admin":false},"assignees":[{"login":"mrjana","id":1693482,"avatar_url":"https://avatars.githubusercontent.com/u/1693482?v=3","gravatar_id":"","url":"https://api.github.com/users/mrjana","html_url":"https://github.com/mrjana","followers_url":"https://api.github.com/users/mrjana/followers","following_url":"https://api.github.com/users/mrjana/following{/other_user}","gists_url":"https://api.github.com/users/mrjana/gists{/gist_id}","starred_url":"https://api.github.com/users/mrjana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrjana/subscriptions","organizations_url":"https://api.github.com/users/mrjana/orgs","repos_url":"https://api.github.com/users/mrjana/repos","events_url":"https://api.github.com/users/mrjana/events{/privacy}","received_events_url":"https://api.github.com/users/mrjana/received_events","type":"User","site_admin":false}],"milestone":null,"comments":47,"created_at":"2016-09-20T17:39:59Z","updated_at":"2016-10-17T20:16:48Z","closed_at":"2016-10-17T20:16:48Z","body":"**Description**\r\n\r\nI have 3 hosts in swarm mode cluster and a service replicated between those hosts. Doing DNS lookup by service name only resolves IP addresses of the containers running on the same host. All hosts are connected to the same custom overlay network (not ingress).\r\n\r\n**Steps to reproduce the issue:**\r\n1. Create a Swarm Mode cluster with multiple hosts.\r\n2. Create an overlay network on the manager. (E.g. `services`).\r\n3. `docker service create --name nginx --replicas 3 --network services nginx`.\r\n4. Go to one of the hosts and do `docker exec -it [container] bash` to one of the containers.\r\n\r\n**Describe the results you received:**\r\nRunning `dig tasks.nginx` in one of the nginx containers resolves only IP addresses for the containers from the same host, not from the whole network.\r\n\r\n**Describe the results you expected:**\r\nDNS resolving for all the containers in the network by service name.\r\n\r\n**Output of `docker version`:**\r\n\r\n```\r\nClient:\r\n Version:      1.12.1\r\n API version:  1.24\r\n Go version:   go1.7\r\n Git commit:   23cf638\r\n Built:        Thu Aug 18 22:32:50 UTC 2016\r\n OS/Arch:      darwin/amd64\r\n\r\nServer:\r\n Version:      1.12.1\r\n API version:  1.24\r\n Go version:   go1.6.3\r\n Git commit:   23cf638\r\n Built:        Thu Aug 18 05:33:38 2016\r\n OS/Arch:      linux/amd64\r\n\r\n```\r\n\r\n**Output of `docker info`:**\r\n\r\n```\r\nContainers: 0\r\n Running: 0\r\n Paused: 0\r\n Stopped: 0\r\nImages: 2\r\nServer Version: 1.12.1\r\nStorage Driver: aufs\r\n Root Dir: /var/lib/docker/aufs\r\n Backing Filesystem: extfs\r\n Dirs: 17\r\n Dirperm1 Supported: true\r\nLogging Driver: json-file\r\nCgroup Driver: cgroupfs\r\nPlugins:\r\n Volume: local\r\n Network: bridge overlay host null\r\nSwarm: active\r\n NodeID: 52nwzxa2zd9taqjebqxgmwuy4\r\n Is Manager: true\r\n ClusterID: 49kqkimxo9qw4nifexpxeb9kh\r\n Managers: 3\r\n Nodes: 3\r\n Orchestration:\r\n  Task History Retention Limit: 5\r\n Raft:\r\n  Snapshot Interval: 10000\r\n  Heartbeat Tick: 1\r\n  Election Tick: 3\r\n Dispatcher:\r\n  Heartbeat Period: 5 seconds\r\n CA Configuration:\r\n  Expiry Duration: 3 months\r\n Node Address: 188.166.146.6\r\nRuntimes: runc\r\nDefault Runtime: runc\r\nSecurity Options: apparmor seccomp\r\nKernel Version: 4.4.0-36-generic\r\nOperating System: Ubuntu 16.04.1 LTS\r\nOSType: linux\r\nArchitecture: x86_64\r\nCPUs: 1\r\nTotal Memory: 992.5 MiB\r\nName: swarm1\r\nID: X4IS:6MJB:MHIU:I4TX:DURB:JBGZ:DOPW:DNSQ:3B7X:CHYI:H5FR:ZBOR\r\nDocker Root Dir: /var/lib/docker\r\nDebug Mode (client): false\r\nDebug Mode (server): false\r\nUsername: burdiyan\r\nRegistry: https://index.docker.io/v1/\r\nLabels:\r\n provider=digitalocean\r\nInsecure Registries:\r\n 127.0.0.0/8\r\n```\r\n\r\n**Additional environment details (AWS, VirtualBox, physical, etc.):**\r\nI was trying that with 3 hosts in DigitalOcean created with Docker Machine. Creating the service with dnsrr endoint mode gave me the same results."},"comment":{"url":"https://api.github.com/repos/docker/docker/issues/comments/254320715","html_url":"https://github.com/docker/docker/issues/26747#issuecomment-254320715","issue_url":"https://api.github.com/repos/docker/docker/issues/26747","id":254320715,"user":{"login":"mavenugo","id":5056191,"avatar_url":"https://avatars.githubusercontent.com/u/5056191?v=3","gravatar_id":"","url":"https://api.github.com/users/mavenugo","html_url":"https://github.com/mavenugo","followers_url":"https://api.github.com/users/mavenugo/followers","following_url":"https://api.github.com/users/mavenugo/following{/other_user}","gists_url":"https://api.github.com/users/mavenugo/gists{/gist_id}","starred_url":"https://api.github.com/users/mavenugo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mavenugo/subscriptions","organizations_url":"https://api.github.com/users/mavenugo/orgs","repos_url":"https://api.github.com/users/mavenugo/repos","events_url":"https://api.github.com/users/mavenugo/events{/privacy}","received_events_url":"https://api.github.com/users/mavenugo/received_events","type":"User","site_admin":false},"created_at":"2016-10-17T20:16:48Z","updated_at":"2016-10-17T20:16:48Z","body":"This is resolved in 1.12.2. Closing the issue. please re-open this if the issue is still seen in 1.12.2"}}
{"actor":{"display_login":"mavenugo"}}