Pcornel
Linux · Linux Troubleshooting

High CPU

Cheat sheet · https://pcornel.dk/topic.php?topic=2913

Back to the Topic

Answer

High CPU means one or more processes (or the kernel) use most of the CPU time, making the system slow.

Remember

Find the process and the kind of time: user (application work), system (kernel, often I/O or networking), steal (VM host). A runaway process or a loop after an update is common.

First checks

  • journalctl -b -p err — errors this boot
  • systemctl --failed — failed units
  • df -h; df -i — space and inodes
  • ss -tulpn — listening sockets
  • dmesg -T | tail — recent kernel messages

Commands

systemctl show nginx -p CPUQuotaPerSecUSec

Verify in this order

workload → process uses CPU → identified → limited or fixed

Where it usually breaks

First mismatch in persistent intent → provider/parser/generator → kernel/userspace runtime → dependency/security context → logs/counters → consumer-visible read-back; preserve identity/native diagnostic/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=2913

Confirmation

Confirm action

Continue?