Skip to content
This repository has been archived by the owner on Jun 29, 2022. It is now read-only.

Add memory requests for nodes and controlplane workloads #49

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Mar 30, 2020

  1. Add memory requests for nodes and controlplane workloads

    This commit adds memory requests for all nodes and controlplane
    workloads. The reason behind it is to better show user available
    resources on both worker and controller nodes e.g. when doing 'kubectl
    describe node'. This is important while one scales the controlplane
    deployments and may prevent node eviction.
    
    The measurment was done on freshly created cluster, with
    prometheus-operator and metrics-server deployed,
    on controller node and on worker node, so the numbers might be lower
    than the numbers on long-running cluster, but they give at least some
    initial visibility.
    
    The values were measured using 'systemd-cgtop -m -1 / --depth=1', not
    using 'free', as 'systemd-cgtop' also includes page cache usage, the
    same way 'kubelet' is measuring the memory usage.
    
    Before the measurment, following command has been executed:
    'sync; echo 1 | sudo tee /proc/sys/vm/drop_caches; sleep 10'
    To make sure only active memory has been captured.
    
    system.slice uses ~250Mi, init.scope uses ~200Mi, which sums up to
    roughly 500Mi, which is needed for system.
    
    Kubelet in /docker slice was using ~100Mi. etcd in /docker slice was
    using ~200Mi, so workers has 100Mi reserved for 'kube' and controllers
    has 300Mi.
    
    Memory usage for self-hosted components has been measured using the
    following command: 'kubectl top pods --sort-by=memory | sort -h -k3 -r'.
    
    Then, the read values were rounded up a bit.
    
    Signed-off-by: Mateusz Gozdek <[email protected]>
    invidian committed Mar 30, 2020
    Configuration menu
    Copy the full SHA
    98fe1b9 View commit details
    Browse the repository at this point in the history
  2. packet worker: move getting BGP_PEER_ADDRESS inline

    To avoid duplicating the template logic and to make the configuration
    more readable, as having quote (") right before the template logic is
    very confusing.
    
    Signed-off-by: Mateusz Gozdek <[email protected]>
    invidian committed Mar 30, 2020
    Configuration menu
    Copy the full SHA
    f907568 View commit details
    Browse the repository at this point in the history