Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kubectl get pvc shows 0 capacity for PersistentVolumeClaim #29425

Closed
saad-ali opened this issue Jul 22, 2016 · 3 comments · Fixed by #29982
Closed

kubectl get pvc shows 0 capacity for PersistentVolumeClaim #29425

saad-ali opened this issue Jul 22, 2016 · 3 comments · Fixed by #29982
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug. sig/storage Categorizes an issue or PR as relevant to SIG Storage.
Milestone

Comments

@saad-ali
Copy link
Member

Bound PersistentVolumeClaim shows 0 capacity

$ gcloud compute disks list
NAME                                 ZONE            SIZE_GB  TYPE         STATUS
disk100-001                          europe-west1-d  100      pd-standard  READY
gke-unrest-micro-pool-199acc6c-3p31  europe-west1-d  100      pd-standard  READY
gke-unrest-micro-pool-199acc6c-4q55  europe-west1-d  100      pd-standard  READY

$ kubectl get pv
NAME             CAPACITY   ACCESSMODES   STATUS    CLAIM                           REASON    AGE
pv-disk100-001   100Gi      RWO           Bound     default/graphite-statsd-claim             2m

$ kubectl get pvc
NAME                    STATUS    VOLUME           CAPACITY   ACCESSMODES   AGE
graphite-statsd-claim   Bound     pv-disk100-001   0                        3m

From http://stackoverflow.com/questions/38463725/persistentvolumemound-bound-but-with-0-capacity-using-kubernetes-on-google-compu

@saad-ali saad-ali added sig/storage Categorizes an issue or PR as relevant to SIG Storage. area/volumes labels Jul 22, 2016
@saad-ali saad-ali added the kind/bug Categorizes issue or PR as related to a bug. label Aug 2, 2016
@saad-ali saad-ali added this to the v1.4 milestone Aug 2, 2016
@wongma7
Copy link
Contributor

wongma7 commented Aug 3, 2016

I found this was introduced by #24331 I think updating pvc capacity got lost in the refactor https://github.com/kubernetes/kubernetes/pull/24331/files#diff-97a1ffdd78274d54ba9dc28656ceca2dL431

@saad-ali saad-ali modified the milestones: v1.3, v1.4 Aug 3, 2016
@saad-ali
Copy link
Member Author

saad-ali commented Aug 3, 2016

@jsafrane can you take a look at this.

@jsafrane
Copy link
Member

jsafrane commented Aug 3, 2016

Someone forgot to update claim.Status.Capacity when binding claims. Fix will follow shortly.

k8s-github-robot pushed a commit that referenced this issue Aug 8, 2016
Automatic merge from submit-queue

Fix PVC.Status.Capacity and AccessModes after binding

Also, fix unit tests to have the same claim and volume sizes in most of the
tests where we don't test matching based on size and test for a specific size
when we do actually test the matching.

Fixes #29425
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. sig/storage Categorizes an issue or PR as relevant to SIG Storage.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants