解决Failed to provision volume with StorageClass "xxx": failed to create rbd image(PVC一直是pending)

气旋面双凤阁 松还有万年枝

目录

 

问题描述

问题解决


问题描述

在rancher上部署应用时使用存储类创建的pvc状态一直是pending状态,应用的pod一直提示:pod has unbound PersistentVolumeClaims

集群存储类状态是active。然后就去看了下存储卷的事件,如图:

解决Failed to provision volume with StorageClass

 

可以看到,报的错是ceph的配置文件没找到:

unable to find a keyring on /etc/ceph/ceph.client.admin.keyring,/etc/ceph/ceph.keyring,/etc/ceph/keyring,/etc/ceph/keyring.bin: (2) No such file or directory

但是已经给每个worker节点已经配置了呀:

[root@cp04 ~]# ls /etc/ceph/
ceph.client.admin.keyring  ceph.conf  rbdmap
[root@cp04 ~]# cd /etc/ceph/
[root@cp04 ceph]# cat ceph.client.admin.keyring 
[client.admin]
	key = AQBTp/BdMy4oDBAAt7GQfJH0KfNGm1wZPk5ZIg==

折腾了很久...

问题解决

检查每个节点的ceph配置文件是否都有,给集群控制节点(master)也加上ceph配置即可

解决Failed to provision volume with StorageClass

 

 

 

你可能感兴趣的:(解决Failed to provision volume with StorageClass "xxx": failed to create rbd image(PVC一直是pending))