Knowledge
How to get top processes with highest CPU usage
#Hosting
Want to know what's causing your server to slow down or what's keeping all these resources for itself. This command shows you which processes take it all.
Published by Mark van Eijk on August 12, 2022 · 1 minute read
Run this commando to show top 10 processes that are using the most CPU on your server:
ps -eo cmd,%cpu --sort=-%cpu | head -n 11
To find memory hogs instead, use top processes by memory; and when a process is holding a port, here's how to kill it.
Subscribe to our newsletter
Do you want to receive regular updates with fresh and exclusive content to learn more about web development, hosting, security and performance? Subscribe now!
More in #Hosting
- How to get top processes with highest memory usage
- How to add Swap Space on Ubuntu servers
- Disable unnecessary and unused PHP versions (FPM pools)
- Reclaim disk space on Ubuntu server
- How to check Ubuntu version
- Zero downtime deployments using PHP-FPM and nginx