Monitoring and Managing Linux Processes

时间:2015-08-28 21:03:25   收藏:0   阅读:193
Overview
Goal To evaluate and control processes running on a Lunix system
Objectives
  • List and interpret basic information about processes running on the system
  • Control processes in the shell? session using bash job control
  • Terminate and control porcesses using singnals
  • Moniror resource usage and system load due to process activity
Sections
  • Processes
  • Controlling Jobs
  • Killing Processes
  • Monitoring Process Activity
Lab Monitoring and Managing Linux Process

 

Section 1: Process

What is process?

A process is a running instance of a launched, executable program. A process consists of:

 

An existing(Parent) process duplicates its own address space(fork) to create a new(child) process structure. Every new process is assigned a unique process ID(PID) for tracking and security. The PID and the Parents? Process ID(PPID) are elements of the new process enviroment. All processes are descendants of the first system process, systemd.

 

Linux process States
Name Flag Kernel-defined state name and description
Running R TASK_RUNNING: The process is either executing on a CPU or waiting to run. Process can be executing user routines or kernel routines(system calls), or be queued and ready when in the Running(or Runnable) state.
Sleeping S TASK_INTERRUPTIBLE:
D TASK_UNINTERRUPTIBLE
K TASK_KILLABLE
Stopped T TASK_STOPPED
T TASK_TRACKED
Zombie Z EXIT_ZOMBIE
X EXIT_DEAD

 

 

 

 

 

 

 

 

 

Listing processes

the ps command is used for listing current processes. The command can provide detailed process infomation, include:

 

Note: The linux version of ps supports three option formats, including:

for example, ps -aux not the same as ps aux

技术分享

 

技术分享

原文:http://www.cnblogs.com/elewei/p/4767696.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!