Posts

Showing posts from April, 2019

Insights to CPU/RAM usage on Linux using the ps command

To see what processes are running on your machine, sorted by their memory usage, run the following command: ps aux | awk '{print $2 , $4 , $11 }' | sort -k2rn | head -n 15 Similar to the above, but with some headings thrown in: echo [PID] [MEM] [PATH] && ps aux | awk '{print $2 , $4 , $11 }' | sort -k2rn | head -n 15 To view similar but CPU focused, not RAM percentage: ps -eo pcpu,pid,user,args | sort -k 1 -r | head -20