查使用内存最多的5个进程:
ps aux | head -1 && ps aux | grep -v USER | sort -nr -k 4 | head -5
查使用CPU最多的5个进程:
ps aux | head -1 && ps aux | grep -v USER | sort -nr -k 3 | head -5
查询僵尸进程
ps -A -o stat,ppid,pid,cmd | grep -e ‘^[Zz]‘
ps -ef | grep defunct | grep -v grep
原文地址:https://www.cnblogs.com/jaxlove-it/p/10219120.html
时间: 2024-11-12 03:47:17