QoS Class (Quality of Service Class)

150

The QoS Class (Quality of Service Class) provides a way for Kubernetes to classify Pods within the cluster into several classes and make decisions about scheduling and eviction.

Stuff you wanna know:

  1. QoS classes are used to make decisions about Pods scheduling and eviction.
  2. QoS Class of a Pod is set at creation time based on its compute resources requests and limits settings.
  3. Kubernetes can assign one of the following QoS classes to a Pod: Guaranteed, Burstable or BestEffort.
  4. For a Pod to be given a QoS class of Guaranteed:
    • Every Container in the Pod must have a memory limit and a memory request.
    • For every Container in the Pod, the memory limit must equal the memory request.
    • Every Container in the Pod must have a CPU limit and a CPU request.
    • For every Container in the Pod, the CPU limit must equal the CPU request.
  5. A Pod is given a QoS class of Burstable if:
    • The Pod does not meet the criteria for QoS class Guaranteed.
    • At least one Container in the Pod has a memory or CPU request or limit.
  6. For a Pod to be given a QoS class of BestEffort, the Containers in the Pod must not have any memory or CPU limits or requests.
  7. The kubelet uses Priority to determine pod order for node-pressure eviction. You can use the QoS class to estimate the order in which pods are most likely to get evicted.

More stuff: