Chinaunix首页 | 论坛 | 博客
  • 博客访问: 625016
  • 博文数量: 110
  • 博客积分: 3808
  • 博客等级: 中校
  • 技术积分: 1930
  • 用 户 组: 普通用户
  • 注册时间: 2010-05-15 14:32
个人简介

声的伟大!

文章分类

全部博文(110)

文章存档

2014年(1)

2013年(2)

2012年(12)

2011年(81)

2010年(14)

分类: LINUX

2010-12-24 20:39:20

LECTURE 10
Investigating and Managing Process
 
Upon completion of this unit,you should be able to:
  • Explain what a process is
  • Description how to manage processes
  • Use fob control tools
  • Employ decision making ucts in shell scripts

进程管理:ps

        -a  显示所有终端机下执行的程序,除了阶段作业领导者之外。

        -e   显示所有的进程

        -u   user shows all process by user

        -F   print extra information

        -H   indents child process

        -o   PROPERTY1,PROPERTY2......用户自定义

            .pid,comm,%cpu,stat,tty,,euser,,ruser,etc.

例如:ps -eo pid,%cpu,comm

     ps aux,ps axjf,ps -lA等等

进程状态:1.运行态(R)2.停止态(T)3.就绪态 4.僵死态(Z)5.睡眠态(S)

     其中在进程状态中:<<高优先级进程,N低优先级进程,s会话发起者,+前台进程组中的进程,l多线程进程

?表示守护进程与tty无关  [ ]内核发起的线程,一个进程可触发多个线程。

pgrep -U user

pgrep -G group

 

静态优先级(0-99),动态优先级(100-139)

nice -n (number) command

renice number PID

注意:nohup 即使logout进程此作业仍然进行:nohup cp /etc/ /tmp 

 

 

阅读(837) | 评论(0) | 转发(0) |
0

上一篇:linux_yum

下一篇:一脚本自动到ftp下载文件

给主人留下些什么吧!~~