[PerlChina] 停止/开始 Perl 脚本后台模式运行

陈学芹 robbiecn at gmail.com
Thu Oct 25 07:51:06 PDT 2007


在 07-10-25,Jesse Lee<cdrplum at gmail.com> 写道:
> 大家好,
>
> 想问个问题,昨天执行了一个脚本 daemon mode,  后来文件修改了一次,又执行了一次命令
> # perl myfile.pl & ,发现运行了两个不同的内容。
> 问一下怎么停止脚本的后台运行?这些运行在哪个文件里?
>
> 谢谢
如果你在同一个终端两次运行perl,后台方式,则可以用
   jobs  -l
命令找出后台的perl任务进程ID,再用kill -9 停止那个进程.

也可以用ps -aux | grep perl 查找出所有的perl进程,进而kill.




-- 
/*
*@author: chen xueqin
*@email: robbiecn at gmail.com
*@see: http://robbie.bokee.com
*@see: http://groups.google.com/group/fzlug
*@love: freedom,tux,open source
*/


More information about the China-pm mailing list