Analysis and application of Linux operating system process management

Source: Internet
Author: User

1, procedures and processes;

A program is a software designed to accomplish a task, such as OpenOffice. What is a process? A process is a running program.

A running program that may have multiple processes. For example, linuxsir.org used by the WWW server is the Apache server, when the administrator started the service, there may be a lot of people to access, that is, many users to request the HTTPD service at the same time, the Apache server will create a number of httpd processes to service it.

1.1 Process classification;

Processes are generally divided into interactive processes, batch processes, and daemon classes.

It is worth mentioning that the daemon is always active, usually in the background, the daemon is usually by the system in the boot automatically activated by the script or Super Admin user root to start. For example, in Fedora or redhat, we can define the run level of the HTTPD server's startup script, which is located in the/ETC/INIT.D directory, the file name is HTTPD,/ETC/INIT.D/HTTPD is the httpd server daemon, When the run level is set to 3 and 5 o'clock, it will start when the system starts.

[Root@localhost ~]# chkconfig--level httpd on

Because the daemon is running all the time, it is in a state of waiting for a request processing task. For example, we are not accessing linuxsir.org, linuxsir.org httpd servers are running, waiting for the user to access, that is, waiting for the task to deal with.

1.2 The attributes of the process;

Process ID (PID): is the only numeric value used to differentiate processes;

ID of the parent process and the parent process (PPID);

The user ID (UID) of the startup process and the group (GID) to which it belongs;

Process status: State is divided into running R, dormant s, zombie Z;

Priority of process execution;

The terminal name to which the process is connected;

Process resource occupancy: For example, resource size (memory, CPU footprint);

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.