coreos / coreos-kubernetes

CoreOS Container Linux+Kubernetes documentation & Vagrant installers
https://coreos.com/kubernetes/docs/latest/
Apache License 2.0
1.1k stars 466 forks source link

nslookup kubernetes.default is stuck whereas nslookup kubernetes works fine #862

Open msavlani opened 7 years ago

msavlani commented 7 years ago

Hi,

I am facing weird issues Kubernetes 1.5.2

Its a single 2 nodes cluster which is setup using "https://kubernetes.io/docs/getting-started-guides/centos/centos_manual_config/"

then i created skydns pods.

[root@masterhost ~]# kubectl get pods -n kube-system NAME READY STATUS RESTARTS AGE kube-dns-v20-jm7x7 3/3 Running 0 2h kubernetes-dashboard-255567031-7dn4l 1/1 Running 44 11d

[root@mwhlvatd2d2 ~]# kubectl get services -n kube-system NAME CLUSTER-IP EXTERNAL-IP PORT(S) AGE kube-dns 10.254.0.10 53/UDP,53/TCP 2h kubelet None 10250/TCP 8d kubernetes-dashboard 10.254.25.228 80:31000/TCP 24d

I created one busybox pod and tried to do nslookup for kubernetes service as follows

It worked fine. [root@masterhost ~]# kubectl exec -ti busybox1 -- nslookup kubernetes Server: 10.254.0.10 Address 1: 10.254.0.10 kube-dns.kube-system.svc.cluster.local

Name: kubernetes Address 1: 10.254.0.1 kubernetes.default.svc.cluster.local

Then i did nslookup for kubernetes.default [root@masterhost ~]# kubectl exec -ti busybox1 -- nslookup kubernetes.default Server: 10.254.0.10 Address 1: 10.254.0.10 kube-dns.kube-system.svc.cluster.local

---- Here it got stuck for some time and then returned following error ;

nslookup: can't resolve 'kubernetes.default'

Expected result

[root@masterhost ~]# kubectl exec -ti busybox1 -- nslookup kubernetes.default.svc.cluster.local Server: 10.254.0.10 Address 1: 10.254.0.10 kube-dns.kube-system.svc.cluster.local

Name: kubernetes.default.svc.cluster.local Address 1: 10.254.0.1 kubernetes.default.svc.cluster.local

Any help here is appreciated.

page-fault-in-nonpaged-area commented 7 years ago

Can confirm. I'm having this issue too.

NAME="Container Linux by CoreOS" ID=coreos VERSION=1353.8.0 VERSION_ID=1353.8.0 BUILD_ID=2017-05-30-2322 PRETTY_NAME="Container Linux by CoreOS 1353.8.0 (Ladybug)" ANSI_COLOR="38;5;75" HOME_URL="https://coreos.com/" BUG_REPORT_URL="https://issues.coreos.com"

Clean installation following the guide.