$ ps -ef | grep PROCESS | grep -v grep | awk '{print $2}'
prints the PID in the output of processes which contains PROCESS in their name.
$ kill -9 `ps -ef | grep oraxpo | grep -v grep | awk '{print $2}'`
to kill them
本文介绍如何使用ps命令、grep命令和awk命令来筛选并终止包含特定字符串的进程,实现对Linux系统中进程的高效管理。
$ ps -ef | grep PROCESS | grep -v grep | awk '{print $2}'
prints the PID in the output of processes which contains PROCESS in their name.
$ kill -9 `ps -ef | grep oraxpo | grep -v grep | awk '{print $2}'`
to kill them
423
3793
3691

被折叠的 条评论
为什么被折叠?