Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Constrain the host sandbox cgroup for devices and cpusets by default when sandbox-cgroup-only selected #2793

Merged
merged 4 commits into from
Jul 16, 2020

Commits on Jul 16, 2020

  1. virtcontainers: add method for calculating cpuset for sandbox

    Calculate sandbox's CPUSet as the union of each of the container's
    CPUSets.
    
    Signed-off-by: Eric Ernst <eric@amperecomputing.com>
    Eric Ernst committed Jul 16, 2020
    Configuration menu
    Copy the full SHA
    1aa0cec View commit details
    Browse the repository at this point in the history
  2. vendor: add cpuset package from kubernetes

    added for calculating union of cpusets
    
    Signed-off-by: Eric Ernst <eric@amperecomputing.com>
    Eric Ernst committed Jul 16, 2020
    Configuration menu
    Copy the full SHA
    9fa2bf1 View commit details
    Browse the repository at this point in the history
  3. cgroups: add ability to update CPUSet

    add function for applying a CPUset change to a cgroup
    
    Signed-off-by: Eric Ernst <eric@amperecomputing.com>
    Eric Ernst committed Jul 16, 2020
    Configuration menu
    Copy the full SHA
    093aaa8 View commit details
    Browse the repository at this point in the history
  4. sandbox: don't constrain cpus, mem only cpuset, devices

    Allow for constraining the cpuset as well as the devices-whitelist . Revert
    sandbox constraints for cpu/memory, as they break the K8S use case. Can
    re-add behind a non-default flag in the future.
    
    The sandbox CPUSet should be updated every time a container is created,
    updated, or removed.
    
    To facilitate this without rewriting the 'non constrained cgroup'
    handling, let's add to the Sandbox's cgroupsUpdate function.
    
    Fixes: #2792
    
    Signed-off-by: Eric Ernst <eric@amperecomputing.com>
    Eric Ernst committed Jul 16, 2020
    Configuration menu
    Copy the full SHA
    8b4c299 View commit details
    Browse the repository at this point in the history