Readiness probe failed:connection refused


我的K8S集群在啟動一個POD的時候說死起不來,然后就報下面的錯誤

Events:
  Type     Reason     Age                    From                                       Message
  ----     ------     ----                   ----                                       -------
  Normal   Scheduled  6m52s                  default-scheduler                          Successfully assigned alpha-vup/alpha-aggregatofrgql to ip-10-xxx-xxx-247.ad.abc.com
  Normal   Started    6m19s (x2 over 6m51s)  kubelet,  ip-10-xxx-xxx-247.ad.abc.com  Started container
  Warning  Unhealthy  5m58s (x6 over 6m48s)  kubelet,  ip-10-xxx-xxx-247.ad.abc.com  Readiness probe failed: Get http://10.xxx.xxx.107:80/: dial tcp 10.xxx.xxx.107:80: connect: connection refused
  Warning  Unhealthy  5m50s (x6 over 6m40s)  kubelet, ip-10-xxx-xxx-247.ad.abc.com  Liveness probe failed: Get http://10.xxx.xxx.107:80/: dial tcp 10.xxx.xxx.107:80: connect: connection refused

 

折騰了好久,解決方案就是注釋掉,下面的行,然后你就可以helm upgrade了

$ cat templates/deployment.yaml
              #          livenessProbe:
              #            httpGet:
              #              path: /
              #              port: http
              #          readinessProbe:
              #            httpGet:
              #              path: /
              #              port: http

總結:Liveness 和readines這兩個健康探針在使用時,你需要確保你的K8S集群中確實這兩個服務


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM