kubernetes.default: Name does not resolve

后端 未结 2 1374
渐次进展
渐次进展 2021-01-23 17:14

Im running OpenShift.

  • OpenShift Master: v3.3.1.7
  • Kubernetes Master: v1.3.0+52492b4

But am having problems trying to run a build in Jenki

相关标签:
2条回答
  • 2021-01-23 17:58

    Please check on manage jenkins -> Configure Global Security -> Agent port is 50000 and Fixed

    0 讨论(0)
  • 2021-01-23 18:14

    First confirm that DNS is actually working with:

    › kubectl run -i -t busybox --image=busybox --restart=Never 
    Waiting for pod default/busybox to be running, status is Pending, pod ready: false
    If you don't see a command prompt, try pressing enter.
    
    / # nslookup kubernetes.default
    Server:    192.168.60.10
    Address 1: 192.168.60.10 kube-dns.kube-system.svc.cluster.local
    
    Name:      kubernetes.default
    Address 1: 192.168.60.1 kubernetes.default.svc.cluster.local
    

    If that doesn't work check if the DNS pods are running:

    kubectl get pods --namespace=kube-system -l k8s-app=kube-dns
    

    Will respond sth like:

    NAME                 READY     STATUS    RESTARTS   AGE
    kube-dns-v14-3u5zi   3/3       Running   36         166d
    

    Finally checking the related logs is worth a try:

    kubectl logs --namespace=kube-system $(kubectl get pods --namespace=kube-system -l k8s-app=kube-dns -o name) -c kube-dns
    kubectl logs --namespace=kube-system $(kubectl get pods --namespace=kube-system -l k8s-app=kube-dns -o name) -c dnsmasq
    kubectl logs --namespace=kube-system $(kubectl get pods --namespace=kube-system -l k8s-app=kube-dns -o name) -c healthz
    

    Full instructions can be found on kubernetes.io

    0 讨论(0)
提交回复
热议问题