I am trying to create pv and pvc resources via kuberctl create -f pv-definition.json but k8s doesn't make any progress and it just kept reporting Pending states for them.
Looked at kubectl get events and logs from api and controller, but I don't see anything related to messages to pv or pvc creation. I have the disk created beforehand on gcloud and I have verified that the name and disk size matches.
The pv definition is very basic:
{
"apiVersion": "v1",
"kind": "PersistentVolume",
"metadata": {
"name": "test-0b-pv"
},
"spec": {
"accessModes": [
"ReadWriteOnce"
],
"capacity": {
"storage": "50Gi"
},
"gcePersistentDisk": {
"fsType": "ext4",
"pdName": "test-0b"
},
"persistentVolumeReclaimPolicy": "Retain"
}
}
Does anyone have any suggestion for debugging? I have restarted k8s-master services to no avail.