{"action":"created","issue":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/13434","labels_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/13434/labels{/name}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/13434/comments","events_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/13434/events","html_url":"https://github.com/kubernetes/kubernetes/issues/13434","id":104232235,"number":13434,"title":"Can't resolve service names on namespace kube-system","user":{"login":"Smana","id":4101366,"avatar_url":"https://avatars.githubusercontent.com/u/4101366?v=3","gravatar_id":"","url":"https://api.github.com/users/Smana","html_url":"https://github.com/Smana","followers_url":"https://api.github.com/users/Smana/followers","following_url":"https://api.github.com/users/Smana/following{/other_user}","gists_url":"https://api.github.com/users/Smana/gists{/gist_id}","starred_url":"https://api.github.com/users/Smana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Smana/subscriptions","organizations_url":"https://api.github.com/users/Smana/orgs","repos_url":"https://api.github.com/users/Smana/repos","events_url":"https://api.github.com/users/Smana/events{/privacy}","received_events_url":"https://api.github.com/users/Smana/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-01T10:03:49Z","updated_at":"2015-09-01T11:10:33Z","closed_at":"2015-09-01T11:10:33Z","body":"Hello,\r\n\r\nI've deployed my cluster on debian based on https://github.com/CiscoCloud/kubernetes-ansible.\r\nEverything work fine except some addons and i suspect name resolution.\r\n\r\nI've a rc defined like this\r\n```\r\napiVersion: v1\r\nkind: ReplicationController\r\nmetadata:\r\n  name: monitoring-influx-grafana-v1\r\n  namespace: kube-system\r\n  labels: \r\n    k8s-app: influxGrafana\r\n    version: v1\r\n    kubernetes.io/cluster-service: \"true\"\r\nspec: \r\n  replicas: 1\r\n  selector: \r\n    k8s-app: influxGrafana\r\n    version: v1\r\n  template: \r\n    metadata: \r\n      labels: \r\n        k8s-app: influxGrafana\r\n        version: v1\r\n        kubernetes.io/cluster-service: \"true\"\r\n    spec: \r\n      containers: \r\n        - image: gcr.io/google_containers/heapster_influxdb:v0.3\r\n          name: influxdb\r\n          resources:\r\n            limits:\r\n              cpu: 100m\r\n              memory: 200Mi\r\n          ports: \r\n            - containerPort: 8083\r\n              hostPort: 8083\r\n            - containerPort: 8086\r\n              hostPort: 8086\r\n          volumeMounts:\r\n          - name: influxdb-persistent-storage\r\n            mountPath: /data\r\n        - image: gcr.io/google_containers/heapster_grafana:v0.7\r\n          name: grafana\r\n          resources:\r\n            limits:\r\n              cpu: 100m\r\n              memory: 100Mi\r\n          env: \r\n            - name: INFLUXDB_EXTERNAL_URL\r\n              value: /api/v1/proxy/namespaces/kube-system/services/monitoring-influxdb:api/db/\r\n            - name: INFLUXDB_HOST\r\n              value: monitoring-influxdb\r\n            - name: INFLUXDB_PORT\r\n              value: \"8086\"\r\n      volumes:\r\n      - name: influxdb-persistent-storage\r\n        emptyDir: {}\r\n```\r\n\r\nSo the container connects to a host named \"monitoring-influxdb\".\r\nActually this name is well resolved by the dns when i use a \"busy-box\" pod:\r\n```\r\nkubectl exec busybox --namespace=kube-system -- nslookup monitoring-influxdb\r\nServer:    10.233.0.10\r\nAddress 1: 10.233.0.10\r\n\r\nName:      monitoring-influxdb\r\nAddress 1: 10.233.83.114\r\n```\r\n\r\nBut inside the monitoring-influx-grafana-v1 pod, the name is not resolved :\r\n```\r\nkubectl exec monitoring-influx-grafana-v1-obu8h --namespace=kube-system -- ping -c 1 monitoring-influxdb\r\nPING monitoring-influxdb.kube-system.svc.osm.local (10.233.83.114) 56(84) bytes of data.\r\n\r\n--- monitoring-influxdb.kube-system.svc.osm.local ping statistics ---\r\n1 packets transmitted, 0 received, 100% packet loss, time 0ms\r\n```\r\n\r\nNote the \"kubernetes\" service is resolved\r\n```\r\nkubectl exec monitoring-influx-grafana-v1-obu8h --namespace=kube-system -- ping -c 1 kubernetes\r\nPING kubernetes.default.svc.osm.local (10.233.0.1) 56(84) bytes of data.\r\n64 bytes from 10.233.0.1: icmp_seq=1 ttl=63 time=0.441 ms\r\n\r\n--- kubernetes.default.svc.osm.local ping statistics ---\r\n1 packets transmitted, 1 received, 0% packet loss, time 0ms\r\n```\r\nThe service is defined as follows in etcd\r\n```\r\n{'apiVersion': 'v1',\r\n 'kind': 'Endpoints',\r\n 'metadata': {'creationTimestamp': '2015-08-31T16:11:47Z',\r\n              'labels': {'kubernetes.io/cluster-service': 'true',\r\n                         'kubernetes.io/name': 'InfluxDB'},\r\n              'name': 'monitoring-influxdb',\r\n              'namespace': 'kube-system',\r\n              'resourceVersion': '219',\r\n              'selfLink': '/api/v1/namespaces/kube-system/endpoints/monitoring-influxdb',\r\n              'uid': 'fab1bd0d-4ffa-11e5-bad3-52540011ed64'},\r\n 'subsets': [{'addresses': [{'ip': '10.233.3.5',\r\n                             'targetRef': {'kind': 'Pod',\r\n                                           'name': 'monitoring-influx-grafana-v1-obu8h',\r\n                                           'namespace': 'kube-system',\r\n                                           'resourceVersion': '391',\r\n                                           'uid': 'fa6fb734-4ffa-11e5-bad3-52540011ed64'}}],\r\n              'ports': [{'name': 'http', 'port': 8083, 'protocol': 'TCP'},\r\n                        {'name': 'api', 'port': 8086, 'protocol': 'TCP'}]}]}\r\n```\r\n\r\ni think this problem causes errors for other pods too\r\n```\r\nkubectl logs kibana-logging-v1-ifztn --namespace=kube-system\r\n...\r\n{\"@timestamp\":\"2015-08-31T16:13:29.082Z\",\"level\":\"info\",\"message\":\"Unable to connect to elasticsearch at http://elasticsearch-logging:9200. Retrying in 2.5 seconds.\",\"node_env\":\"production\"}\r\n...\r\n\r\nkubectl logs monitoring-heapster-v8-9cy06 --namespace=kube-system\r\n...\r\nE0831 16:12:27.367871       1 driver.go:326] Database creation failed: Post http://monitoring-influxdb:8086/db?u=root&p=root: dial tcp: lookup monitoring-influxdb: no such host. Retrying after 30 seconds\r\n...\r\n```\r\n\r\nRegards,\r\nSmana\r\n"},"comment":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/comments/136676519","html_url":"https://github.com/kubernetes/kubernetes/issues/13434#issuecomment-136676519","issue_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/13434","id":136676519,"user":{"login":"gmarek","id":1703842,"avatar_url":"https://avatars.githubusercontent.com/u/1703842?v=3","gravatar_id":"","url":"https://api.github.com/users/gmarek","html_url":"https://github.com/gmarek","followers_url":"https://api.github.com/users/gmarek/followers","following_url":"https://api.github.com/users/gmarek/following{/other_user}","gists_url":"https://api.github.com/users/gmarek/gists{/gist_id}","starred_url":"https://api.github.com/users/gmarek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gmarek/subscriptions","organizations_url":"https://api.github.com/users/gmarek/orgs","repos_url":"https://api.github.com/users/gmarek/repos","events_url":"https://api.github.com/users/gmarek/events{/privacy}","received_events_url":"https://api.github.com/users/gmarek/received_events","type":"User","site_admin":false},"created_at":"2015-09-01T11:10:33Z","updated_at":"2015-09-01T11:10:33Z","body":"Please re-post your question to [stackoverflow](http://stackoverflow.com/questions/tagged/kubernetes). \r\n\r\nWe are trying to consolidate the channels to which questions for help/support are posted so that we can improve our efficiency in responding to your requests, and to make it easier for you to find answers to frequently asked questions and how to address common use cases. \r\n\r\nWe regularly see messages posted in multiple forums, with the full response thread only in one place or, worse, spread across multiple forums. Also, the large volume of support issues on github is making it difficult for us to use issues to identify real bugs.\r\n\r\nThe Kubernetes team scans stackoverflow on a regular basis, and will try to ensure your questions don't go unanswered.\r\n\r\nBefore posting a new question, please search stackoverflow for answers to similar questions, and also familiarize yourself with:\r\n  * [the user guide](http://kubernetes.io/v1.0/)\r\n  * [the troubleshooting guide](http://kubernetes.io/v1.0/docs/troubleshooting.html)\r\n\r\nAgain, thanks for using Kubernetes.\r\n\r\nThe Kubernetes Team"}}