进程 kill


$ ps -ef
……
smx          1822       1   0 11:38 ?            00:00:49 gnome-terminal
smx          1823   1822   0 11:38 ?            00:00:00 gnome-pty-helper
smx          1824   1822   0 11:38 pts/0      00:00:02 bash
smx          1827       1   4 11:38 ?            00:26:28 /usr/lib/firefox-3.6.18/firefox-bin
smx          1857   1822   0 11:38 pts/1      00:00:00 bash
smx          1880   1619   0 11:38 ?            00:00:00 update-notifier
……
smx         11946   1824   0 21:41 pts/0      00:00:00 ps -ef
或者:
$ ps -aux
……
smx          1822   0.1   0.8   58484 18152 ?            Sl    11:38    0:49 gnome-terminal
smx          1823   0.0   0.0    1988    712 ?            S      11:38    0:00 gnome-pty-helper
smx          1824   0.0   0.1    6820   3776 pts/0      Ss    11:38    0:02 bash
smx          1827   4.3   5.8 398196 119568 ?          Sl    11:38   26:13 /usr/lib/firefox-3.6.18/firefox-bin
smx          1857   0.0   0.1    6688   3644 pts/1      Ss    11:38    0:00 bash
smx          1880   0.0   0.6   41536 12620 ?            S      11:38    0:00 update-notifier
……
smx         11953   0.0   0.0    2716   1064 pts/0      R+    21:42    0:00 ps -aux

此时如果我想杀了火狐的进程就在终端输入:
$ kill -s 9 1827
其中-s 9 制定了传递给进程的信号是9,即强制、尽快终止进程。各个终止信号及其作用见附录。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值