我對Kubernetes環境有疑問。我有K8s雲,並且在我添加後爲其分配一個持久體積到一個吊艙,此吊艙仍處於「ContainerCreating」狀態。該PV已正確分配PVC。 PVC是與副本兩個外部GlusterFS服務器2.Kubernetes吊艙仍處於「ContainerCreating」狀態
PV看起來就像這樣:
apiVersion: v1
kind: PersistentVolume
metadata:
annotations:
definitionVersion: "20170919"
name: tarsier-pv
spec:
accessModes:
- ReadWriteMany
capacity:
storage: 50Gi
glusterfs:
endpoints: glusterfs-cluster
path: tarsier-prep
persistentVolumeReclaimPolicy: Recycle
PVC看起來就像這樣:
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: tarsier-pvc
annotations:
definitionVersion: "20170919"
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 50Gi
volumeName: tarsier-pv
status:
accessModes:
- ReadWriteMany
capacity:
storage: 50Gi
phase: Bound
莢RC是這樣的:
apiVersion: v1
kind: ReplicationController
metadata:
name: xxx
spec:
replicas: 1
template:
metadata:
labels:
app: xxxxx
spec:
volumes:
- name: tarsier-pv
persistentVolumeClaim:
claimName: tarsier-pvc
...
containers:
- name: xxx
...
volumeMounts:
- name: tarsier-pv
mountPath: "/shared_data/storage"
Kubectl describe pod xxx return no errors。
kubectl日誌XXX返回此:
Error from server (BadRequest): container "xxx" in pod "xxx" is waiting to start: ContainerCreating.
你有任何想法可能是錯誤的或者在哪裏可以找到任何詳細的日誌? THX提前。
編輯: Gluster安裝是否正確安裝在主,如果我手動添加有什麼文件,這是正確複製兩個Gluster服務器
格式,以便更清楚 –
似乎沒有成爲一個'image'從你的配置上面 –
嗨, THX答覆創建的貨櫃你上面的第一粘貼的配置,但這不是重點。這個RC被縮短了。在其他測試環境中,它工作正常。如果沒有可用的圖像,那麼在kubectl describe pod xxx和pod的狀態將會是「ImagePullBackoff」。你還有其他建議嗎? – Bendik