#!/bin/bash
/bin/ps axf -o "pid %cpu" | awk '{if($2>=75.0) print $1}' | while read procid
do
kill -9 $procid
done
#!/bin/bash
/bin/ps axf -o "pid %cpu" | awk '{if($2>=75.0) print $1}' | while read procid
do
kill -9 $procid
done
本文标题:linux 监控并kill掉占用cpu过多的进程
本文链接:https://www.haomeiwen.com/subject/uwssxqtx.html
网友评论