Memory Requests And Limits In Kubernetes

 

  1. “Requests” are usually used to determine the average consumption.
  2. “Limits” set the max number of resources allowed.
The Kubernetes scheduler works best with requests
The kubelet terminates the container when it goes over the memory limit
The kubelet evict pods if the node is running low on resources
  1. Guaranteed
  2. Burstable
  3. BestEffort
Guaranteed Quality of Service for Pods
burstable Quality of Service for Pods
Burstable Quality of Service for Pods
With Burstable pods you can dymically allocate resources as the container needs them
With Guaranteed pods, resources are allocated upfront and can't be freed even if the process isn't using them
You can fit as many BestEffort pods in a node as you wish
Pod PriorityClass
Pods with lower priority are evicted to make space for higher priority pods
REQ = NODE_MEM / MAX_PODS_PER_NODE
Assigning requests for your pods
Measuring memory consumption with the Vertical Pod Autoscaler

Comments

Popular posts from this blog

System Design Interview Guide (2023) | Preparation Strategies and Practical Tips

Cost of the Cloud Computing Resources in 2023