^_^

2009年3月27日星期五

在linux下如何停止指定参数信息的进程

我们运行了一个带参数的进程,如:
# less /home/test.txt
我们要如何才能根据被打开的文件名“test.txt”来结束这个进程?如下:
# kill -9 `ps -e -o pid,args | grep '[t]est.txt' | awk '{print $1}'`
本站文章除注明外,均为本站原创
转载请注明文章转载自: 大笨熊乐园 [ https://blog.foolbear.com/ ]
文章标题: 在linux下如何停止指定参数信息的进程
文章地址: https://blog.foolbear.com/2009/03/linux_27.html

没有评论 :

发表评论

Related Posts with Thumbnails