kubernetes pod status ContainerCreating

如图:status状态为running则对外访问正常,如果为containercreating,则表示异常

解决方法:

先查看/etc/docker/certs.d/registry.access.redhat.com目录下

发现问题:软链接失效,没有这个文件,可能是没有安装,也可能是其他原因

执行:yum install *rhsm* -y

安装完成后执行:docker pull registry.access.redhat.com/rhel7/pod-infrastructure:latest

依然报错:

执行:wget http://mirror.centos.org/centos/7/os/x86_64/Packages/python-rhsm-certificates-1.19.10-1.el7_4.x86_64.rpm

执行:rpm2cpio python-rhsm-certificates-1.19.10-1.el7_4.x86_64.rpm | cpio -iv --to-stdout ./etc/rhsm/ca/redhat-uep.pem | tee /etc/rhsm/ca/redhat-uep.pem

此时,查看/etc/rhsm/ca/目录下是否含有redhat-uep.pem文件

有的话,再次查看/etc/docker/certs.d/registry.access.redhat.com目录

红色变为淡蓝色表示成功,问题解决

重新创建容器

### Kubernetes Static Pod Documentation and Usage Static Pods are managed directly by the kubelet daemon on a specific node, without the need for the API server to manage them. These pods are always tied to the node where they reside and cannot be controlled via standard Kubernetes controllers like Deployments or ReplicaSets. To define a static pod, one must place its manifest file into a directory watched by the `kubelet`. By default, this is `/etc/kubernetes/manifests` on most systems[^4]. When the `kubelet` detects changes in any of these files (addition, modification, deletion), it will adjust the set of running containers accordingly. For example, consider creating a simple nginx static pod: ```yaml apiVersion: v1 kind: Pod metadata: name: nginx spec: containers: - name: nginx image: nginx ``` Save this configuration as `/etc/kubernetes/manifests/nginx.yaml`, after which the `kubelet` service should automatically start an instance of the specified container on that particular machine. Unlike regular pods created through the API server, there's no direct way to interact with static pods using `kubectl apply` commands because they do not exist within etcd database nor have corresponding objects inside the cluster state maintained by apiserver. However, once started, users can still inspect logs, describe status, delete manually from filesystem level but all operations related specifically to managing lifecycle such as scaling up/down replicas aren't applicable here since those features rely heavily upon higher-level abstractions provided by other components outside just the local node itself.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值