阅读背景:

如何在Linux上的python中使用%cpu超过给定时间杀死特定进程?

来源:互联网 

I have this script in python on linux which deploys vnc locally, does some graphical job on this vnc screen, and kills vnc. Sometimes after the job is done process named gnome-panel hangs and stays with 100% cpu usage. Then I need to log in through putty and kill all those processes manually (sometime lots of them actually). I would like to add few lines to my python script when it finishes its job, which will not only kill vnc (it does it already), but also kill gnome-panel if it consumes certain amount of cpu over given time period. I cant simply kill all gnome-panels, as some of them are working fine (im deploying 4 vnc screens at the same time).I have this script in python on linux which dep




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: