-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Add metric for persistent volume size #555
Comments
PersistentVolume sizes are specific to the provider. The kubelet exposes metrics about PersistentVolumeClaims mounted on the particular node, maybe that's what you are looking for? |
Capacity is a field that isn't provider specific. It's how a PVC knows if a PV (created manually or not) if it's big enough to fulfill a PVC.
|
Sorry you’re absolutely right. I was thinking about the usage of the volume. This seems reasonable. |
Kubernetes exposes metrics regarding the volume size : kubelet_volume_stats_available_bytes @brancz Would it be possible for kube-state-metrics to retrieve them to expose them later? |
kube-state-metrics strictly only converts API objects into metrics, as long as this is not part of a Kubernetes API object, kube-state-metrics will not expose it. |
@brancz This is exposed by the kube API. PVs have a stoage capacity just like PVCs have a requested capacity. This isn't about used. |
@brancz Ah, I see. I agree. I will end up using this above metrics in the future, but that's another story. (I don't think those are collected yet) |
Capacity and request are valid as they come directly from API objects, but not any of these:
|
OK thank's for your reply @brancz. |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
/remove-lifecycle stale |
Is this a BUG REPORT or FEATURE REQUEST?:
Feature
/kind feature
What happened:
What you expected to happen:
It would be helpful to see the size of persistent volumes.
How to reproduce it (as minimally and precisely as possible):
Anything else we need to know?:
Environment:
kubectl version
):The text was updated successfully, but these errors were encountered: