任务ID:
- pid: 进程ID
- tid:线程ID
- tgid:主线程ID
显示线程需要增加 L参数
| |
任务状态:
进程状态描述:
D uninterruptible sleep (usually IO)
R running or runnable (on run queue)
S interruptible sleep (waiting for an event to complete)
T stopped by job control signal
t stopped by debugger during the tracing
W paging (not valid since the 2.6.xx kernel)
X dead (should never be seen)
Z defunct (“zombie”) process, terminated but not reaped by
its parent
| |
亲缘关系:
ppid: 父进程ID, real parent
| |
优先级相关:
优先执行序 prority,PRI, 值越小优先级越高
通过ps可以查看,PRI(new) = PRI(old) + nice
通过nice,renice可以进行调整。普通用户仅能调打NI (0~19)
root调整范围(-20~19)
| |
调度相关:
调度相关策略
- not reported
TS SCHED_OTHER
FF SCHED_FIFO
RR SCHED_RR
B SCHED_BATCH
ISO SCHED_ISO
IDL SCHED_IDLE
? unknown value
scheduling policy of the process.
SCHED_OTHER (SCHED_NORMAL),
SCHED_FIFO,SCHED_RR, SCHED_BATCH, SCHED_ISO, and SCHED_IDLE are respectively
displayed as 0, 1, 2, 3, 4, and 5.
| |
信号相关:
- caught: 捕捉信号的掩码
- ignored:忽略信号的掩码
- pending:未决信号掩码
| |
进程权限:
| |
| |
内存相关:
- VSZ: process 使用虚拟内存
- RSS:process使用的固定内存
- TRS:代码段
- DRS:数据段
SIZE和RSS字段不计算进程的某些部分,包括页表,内核堆栈,
struct thread_info和struct task_struct。 这通常至少是20 KiB的内存。SIZE是进程的虚拟大小(代码+数据+堆栈)。
VSZ = TRS+DRS+1?
| |
文件与文件系统:
可以通过fuser,lsof 查看相关文件相关的进程
| |
运行时间统计
| |
capabilities设置及查看
- getcap [pid]
- setcap
| |