过滤掉grep本身进程

使用ps -ef|grep test列出包含test关键字的进程时,会包含grep test本身。
可以利用-v操作过滤,即:
ps -ef|grep test|grep -v grep

猜你喜欢

转载自sarawon.iteye.com/blog/1900095