k8s容器启动不了,一直重启, 报红提示Not Ready

k8s容器启动不了,一直重启, 报红提示Not Ready

反复多次重启后,才能够启动成功。

发现是 启动时间过长,不断达到了失败阈值,于是会不断重启。

将 failureThreshold、 initialDelaySeconds、periodSeconds 这几个参数设置大一些,就可以启动了。

k8s探针类型及探针配置:

详情见: https://blog.csdn.net/sinat_32502451/article/details/139837159

示例:

		  livenessProbe:
            failureThreshold: 6
            httpGet:
              path: /my-service/act/health
              port: 8110
              scheme: HTTP
            initialDelaySeconds: 60
            periodSeconds: 20
            successThreshold: 1
            timeoutSeconds: 5
          name: my-service
          ports:
            - containerPort: 8110
              protocol: TCP
          readinessProbe:
            failureThreshold: 6
            httpGet:
              path: /my-service/act/health
              port: 8110
              scheme: HTTP
            initialDelaySeconds: 60
            periodSeconds: 20
            successThreshold: 1
            timeoutSeconds: 5
相关推荐
Linux运维老纪1 小时前
DNS缓存详解(DNS Cache Detailed Explanation)
计算机网络·缓存·云原生·容器·kubernetes·云计算·运维开发
JunLan~7 小时前
Docker 部署 GLPI(IT 资产管理软件系统)
运维·docker·容器
青草地溪水旁7 小时前
c++ list的front和pop_front的概念和使用案例
c++·容器·list
元气满满的热码式10 小时前
K8S部署DevOps自动化运维平台
运维·kubernetes·devops
LUCIAZZZ10 小时前
基于Docker以KRaft模式快速部署Kafka
java·运维·spring·docker·容器·kafka
IT艺术家-rookie14 小时前
k8s--部署k8s集群--控制平面节点
容器·kubernetes
康世行15 小时前
Windows环境下MaxKB大模型 Docker部署图文指南
windows·docker·容器
Elastic 中国社区官方博客15 小时前
使用 Ollama 和 Kibana 在本地为 RAG 测试 DeepSeek R1
大数据·数据库·人工智能·elasticsearch·ai·云原生·全文检索
Linux运维老纪1 天前
windows部署deepseek之方法(The Method of Deploying DeepSeek on Windows)
linux·人工智能·分布式·云原生·运维开发·devops
Elastic 中国社区官方博客1 天前
Elastic Cloud Serverless 获得主要合规认证
大数据·数据库·elasticsearch·搜索引擎·云原生·serverless·全文检索