linux进程的状态


在使用ps命令的时候有一列为进程的状态,例如

[davidp@supernova:~]$ ps u  

USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND

davidp 3995 0.0 0.4 3324 1956 pts/2 Ss Aug17 0:00 /bin/bash

davidp 25049 0.0 0.8 7104 3908 pts/5 S+ Aug19 0:10 irssi

davidp 26180 0.0 0.1 2656 908 pts/0 R+ 14:41 0:00 ps u

 

其中STAT列为进程的状态

 

The codes used are:

CodeMeaning
DUninterruptible sleep (usually IO)
RRunning or runnable (on run queue)
SInterruptible sleep (waiting for an event to complete)
TStopped, either by a job control signal or because it is being traced.
Wpaging (not valid since the 2.6.xx kernel)
Xdead (should never be seen)
ZDefunct (“zombie”) process, terminated but not reaped by its parent.

For BSD formats and when the stat keyword is used, additional characters may be displayed:

CodeMeaning
<high-priority (not nice to other users)
Nlow-priority (nice to other users)
Lhas pages locked into memory (for real-time and custom IO)
sis a session leader
lis multi-threaded (using CLONE_THREAD, like NPTL pthreads do)
+is in the foreground process group

~~DISCUSSION~~

 

转自:http://wiki.preshweb.co.uk/doku.php?id=linux:psflags 
 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值