-
Notifications
You must be signed in to change notification settings - Fork 17
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
[BUG]: Resource quota bypass #1163
Comments
@tnrms007: Thank you for submitting this issue! The issue is currently awaiting triage. Please make sure you have given us as much context as possible. If the maintainers determine this is a relevant issue, they will remove the needs-triage label and respond appropriately. We want your feedback! If you have any questions or suggestions regarding our contributing process/workflow, please reach out to us at container.storage.modules@dell.com. |
/sync |
link: 21589 |
@tnrms007 we are looking into this -- can you provide the kubectl describe of the storageclass and resource quota you used as well as either a copy-paste or screenshot of the logs you have from creating the pvc and checking the size of the pvc and resource quota? |
hi here, logs and test information. OSRed Hat Enterprise Linux release 8.6 (Ootpa) k8s (Higher versions are not tested)v1.20.5 2. csi-powerflex versionThe same phenomenon occurs in all versions of csi powerflex (2.2.0 ~ 2.8.0)csi-attacher:v4.2.0 StorageClass$ kubectl get sc powerflexos-xfs-sc-300t -o yaml allowVolumeExpansion: true
StorageQuota$ kubectl get resourcequotas ## Before creating pvc $ kubectl get sc ## Storageclass with different VOLUMEBINDINGMODE $ kubectl get pvc ## pvc created with csi-powerflex $ kubectl get resourcequotas ## The requested volume size and allocated volume size are different. |
@tnrms007 Thanks so much for the logs and for testing/finding this discrepancy. As an initial update, what is happening is that our driver is taking the CreateVolume request from K8s and upsizing the volume size to the next multiple of 8 (because the PowerFlex array only allocates storage in 8 Gi chunks, this is out of our control). However, Kubernetes appears to base the requests.storage field in the resourcequota off of the request, not the actual PV/PVC we create as a result of the request. We are exploring how we can address this and will keep you posted. |
Bug Description
If you set 1Gi in resources.storage when creating pvc, 8Gi (multiple of 8) is actually created, but the resource quota is set to 1Gi. Because of this problem, users may use more resources. ex) Even if a 10Gi limit is set, 80Gi can be used.
Logs
kubectl get pvc test
test ~ 8GI
kubectl get resourcequota
test 1Gi/50Gi
Screenshots
No response
Additional Environment Information
No response
Steps to Reproduce
Allocate pvc as 1Gi and check resourcequota.
Expected Behavior
Resourcequota should be searched with the value assigned by the csi driver.
CSM Driver(s)
csi powerflex 2.2 ~ latest
Installation Type
No response
Container Storage Modules Enabled
No response
Container Orchestrator
kubernetes 1.22 ~ 1.26
Operating System
RHEL 8 / Cent 7.9
The text was updated successfully, but these errors were encountered: