Breaking News: Grepper is joining You.com. Read the official announcement!
Check it out

Differences between memory and CPU limits#

Sumit Rawal answered on June 19, 2023 Popularity 1/10 Helpfulness 1/10

Contents


More Related Answers

  • linux command to check cpu utilization corewise
  • Limit ClamAV CPU Usage
  • Limiting available CPUs
  • Defining Container Memory and CPU Resources
  • CPU requests and limits#
  • check pc ram and cpu

  • Differences between memory and CPU limits#

    0

    There is a difference in what happens to a container when it reaches its limit for CPU and memory usage. CPU is a compressible resource, which means Kubernetes can just stop giving that specific container CPU time if a container tries to use more CPU than it should. The container will not be killed. It will just not have to keep running with the amount of CPU time it has available.

    With memory, it’s different. If a container tries to allocate more memory than it can, Kubernetes will kill the process. Then, depending on the restartPolicy that is defined for this pod, it can be restarted.

    Using LimitRange

    So we saw that defining resource requests are useful to help Kubernetes schedule our pod in a node that has enough resources and defining a limit will guarantee that a rogue container won’t affect other applications sharing the same worker node. It is a good idea to always set these properties.

    Kubernetes allows us to define a LimitRange with default values that will be used for every container that we run in a namespace.

    Popularity 1/10 Helpfulness 1/10 Language whatever
    Source: Grepper
    Link to this answer
    Share Copy Link
    Contributed on Jun 19 2023
    Sumit Rawal
    0 Answers  Avg Quality 2/10


    X

    Continue with Google

    By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
    X
    Grepper Account Login Required

    Oops, You will need to install Grepper and log-in to perform this action.