In kubernetes, for a Pod we specify memory limit and request. There is a PVC which is requested out from PV and created. How do PVC and memory limits corelate during memory allocation and usage, and what if there are conflicts between the two? I am little confused that any one could have served the purpose.
2 Answers
There is no corelation between PVC and memory limits and requests. PVC provides storage space and memory limit and requests provides RAM.

- 41,002
- 9
- 78
- 107
-
If so then can a PVC be shared by multiple pods ? – Firoz Feb 22 '20 at 08:48
-
It depends on the underlying volume type. Some do support multiple access, though often only in read-only mode. – coderanger Feb 22 '20 at 09:06
How do PVC and memory limits corelate during memory allocation and usage, and what if there are conflicts between the two?
There is no direct correlation between Resource Limits and PVC.
It's common to get a little confuse with the word memory as it's a generic term.
Kubernetes uses the word memory as commonly we call RAM Memory which has it's Default Value, and it's Minimum and Maximum Values set into the cluster configuration.
If so then can a PVC be shared by multiple pods ?
Yes, you can share a Persistent Volume with diferent pods in the same namespace.
There are many types of Storage Volumes, which servers different purposes.
A PersistentVolumeClaim (PVC) is used to mount a PersistentVolume into a Pod.

- 3,814
- 1
- 9
- 19