V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
mengjisang
V2EX  ›  Kubernetes

大変だk8s 运行过程中 coredns 运行失败, describe pod 报错 Readiness probe failed: HTTP probe failed with statuscode: 503

  •  
  •   mengjisang · 2023-05-04 11:09:07 +08:00 · 1126 次点击
    这是一个创建于 580 天前的主题,其中的信息可能已经有所发展或是发生改变。

    hj@ubuntu-master:~/Desktop$ kubectl get pods -A NAMESPACE NAME READY STATUS RESTARTS AGE default nginx-deploy-54844bd945-tvf8x 1/1 Running 1 (6d18h ago) 6d19h kube-flannel kube-flannel-ds-65flk 1/1 Running 1 (6d18h ago) 7d10h kube-flannel kube-flannel-ds-gb94l 1/1 Running 1 (6d18h ago) 7d10h kube-flannel kube-flannel-ds-lvzm8 1/1 Running 0 6d18h kube-system coredns-6ccdb8cbf5-bh9rr 0/1 Running 0 15m kube-system coredns-6ccdb8cbf5-m4vc6 0/1 Running 0 15m kube-system coredns-cf9795fd4-4wl2s 0/1 Running 0 22m kube-system etcd-ubuntu-master 1/1 Running 8 (6d19h ago) 7d10h kube-system kube-apiserver-ubuntu-master 1/1 Running 8 (6d19h ago) 7d10h kube-system kube-controller-manager-ubuntu-master 1/1 Running 8 (6d19h ago) 7d10h kube-system kube-proxy-5cw6r 1/1 Running 1 (6d18h ago) 6d19h kube-system kube-proxy-lbmwg 1/1 Running 2 (6d19h ago) 6d19h kube-system kube-proxy-vspn5 1/1 Running 1 (6d18h ago) 6d19h kube-system kube-scheduler-ubuntu-master 1/1 Running 8 (6d19h ago) 7d10h

    hj@ubuntu-master:~/Desktop$ kubectl describe pod coredns-6ccdb8cbf5-bh9rr -n kube-system Name: coredns-6ccdb8cbf5-bh9rr Namespace: kube-system Priority: 2000000000 Priority Class Name: system-cluster-critical Service Account: coredns Node: huangji-ubuntu2004-k8s-subnode1/192.168.15.108 Start Time: Wed, 03 May 2023 19:52:02 -0700 Labels: k8s-app=kube-dns pod-template-hash=6ccdb8cbf5 Annotations: kubectl.kubernetes.io/restartedAt: 2023-05-03T19:38:23-07:00 Status: Running IP: 10.244.1.23 IPs: IP: 10.244.1.23 Controlled By: ReplicaSet/coredns-6ccdb8cbf5 Containers: coredns: Container ID: containerd://60f302d4ec5e67758daba76c0c8efc373dccb41e1b571080e775240f7c658e67 Image: registry.aliyuncs.com/google_containers/coredns:v1.9.3 Image ID: registry.aliyuncs.com/google_containers/coredns@sha256:8e352a029d304ca7431c6507b56800636c321cb52289686a581ab70aaa8a2e2a Ports: 53/UDP, 53/TCP, 9153/TCP Host Ports: 0/UDP, 0/TCP, 0/TCP Args: -conf /etc/coredns/Corefile State: Running Started: Wed, 03 May 2023 19:52:02 -0700 Ready: False Restart Count: 0 Limits: memory: 170Mi Requests: cpu: 100m memory: 70Mi Liveness: http-get http://:8080/health delay=60s timeout=5s period=10s #success=1 #failure=5 Readiness: http-get http://:8181/ready delay=0s timeout=1s period=10s #success=1 #failure=3 Environment: <none> Mounts: /etc/coredns from config-volume (ro) /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-4sxbf (ro) Conditions: Type Status Initialized True Ready False ContainersReady False PodScheduled True Volumes: config-volume: Type: ConfigMap (a volume populated by a ConfigMap) Name: coredns Optional: false kube-api-access-4sxbf: Type: Projected (a volume that contains injected data from multiple sources) TokenExpirationSeconds: 3607 ConfigMapName: kube-root-ca.crt ConfigMapOptional: <nil> DownwardAPI: true QoS Class: Burstable Node-Selectors: kubernetes.io/os=linux Tolerations: CriticalAddonsOnly op=Exists node-role.kubernetes.io/control-plane:NoSchedule node.kubernetes.io/not-ready:NoExecute op=Exists for 300s node.kubernetes.io/unreachable:NoExecute op=Exists for 300s Events: Type Reason Age From Message


    Normal Scheduled 16m default-scheduler Successfully assigned kube-system/coredns-6ccdb8cbf5-bh9rr to huangji-ubuntu2004-k8s-subnode1 Normal Pulled 16m kubelet Container image "registry.aliyuncs.com/google_containers/coredns:v1.9.3" already present on machine Normal Created 16m kubelet Created container coredns Normal Started 16m kubelet Started container coredns Warning Unhealthy 93s (x104 over 16m) kubelet Readiness probe failed: HTTP probe failed with statuscode: 503

    mengjisang
        1
    mengjisang  
    OP
       2023-05-04 11:19:11 +08:00
    解决了,要关闭 防火墙服务,
    sudo systemctl stop firewalld
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   1051 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 19:25 · PVG 03:25 · LAX 11:25 · JFK 14:25
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.