microk8s: High CPU usage when standalone
What did you do?
- I started microK8s cluster
What did you expect to happen?
I expect CPU usage to be around 5%, but it oscillates between 40-80% CPU
top -o cpu
PID COMMAND %CPU TIME #TH #WQ #PORT MEM PURG CMPRS PGRP PPID STATE BOOSTS %CPU_ME %CPU_OTHRS UID FAULTS COW MSGSENT
71452 hyperkit 72.0 12:29.26 12 1 39 4485M 0B 391M 60028 60028 sleeping *0[1] 0.00000 0.00000 0 1226131+ 460 165
Which OS & Architecture?
- MacOS 10.14.6 (18G4032)
- x86
I don’t know how to obtain the tarball created by microk8s inspect from the VM
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 8
- Comments: 26 (3 by maintainers)
Observing this same problem on Ubuntu 20.04 (running on a raspberry PI 4) 😦
yes, i also have high cpu load on idle microk8s.
i did nothing but “snap install microk8s --classic” and kube-apiserver is constantly >10% cpu load.
i see this in the logs every 2 seconds:
journalctrl telling
there is tons of futex() syscalls
disabling ha-cluster made no difference
OS: Ubuntu 20.04 Server LTS x86_64 with all updates MicroK8S: v1.20.4 classic Kernel: 5.4.0-67-generic CPU: proxmox/kvm hypervisor/ 4vCPU on Dual-CPU Xeon L5630 @ 2.13GHz System RAM: 8GB
I’m have a standalone microk8s on a Raspberry Pi 4, 8GB on Ubuntu 21.10 - disabling the ha-cluster feature dropped CPU load and utilization significantly:
microk8s disable ha-clusterSame problem here. Installation for 3 nodes in HA mode. Ubuntu 20.04 version v1.20.1-34 + e7db93d188d0d1.
kube-apiserver uses most of the CPU and the api may become unresponsive and this happens very often, every few minutes. Especially very noticeable after installing any additions depending on kube-apiserver. May be there is a workaround. Can’t release the cluster to production 😦
I confirm, cluster of 5x RaspberryPI4 8GB + ubuntu 21.10 + microk8s 1.22/stable, after disabling ha-cluster all CPUs load dropped from ~80% (some CPUs was on ~60%) to less than 10% No custom pods running, just fresh install and join 4 nodes to 1 master
We have the same problem, ubuntu 20.04. api-server.log
In addition to the loaded processor, constant loss of connection with the api server. Very long operations during writing and reading from dqlite are confusing, some of them reach several seconds. Seems like missing required base indexes. We use modern hard drives with a connected ssd cache
I have same problem, it took ~30% (in peak, even 40-60%) of my CPU I5 8300H, and my laptop was noisy, when I turned mikrok8s off, I had only ~2% CPU usage, and my CPU get cooler by 10°C.
(official installation (sudo snap install microk8s --classic) on Ubuntu 20.04)