Linux Command--ps command

Source: Internet
Author: User

The PS command is used to list the processes currently running on the system. Use this command to determine which processes are running and running, whether the process is complete, if the process is dead, which processes are consuming too many resources, and so on

There are 5 types of processes on Linux: 1. Running (running or waiting in the running queue) 2. Interrupts (dormant, blocked, waiting for a condition to form or receive to signal) 3. Non-interruptible (the received signal does not wake up and is not operational, the process must wait until there is an outage) 4. Zombie (The process has been terminated, but the process descriptor exists until the parent process calls WAIT4 () after the system call is released) 5. Stop (process received Sigstop, SIGSTP, Sigtin, stop running after Sigtou signal) PS tool identifies 5 status codes for the process: D non-interruptible uninterruptible sleep (usually IO) R run runnable ( On run queue) S interrupt sleeping T stop traced or stopped Z zombie a defunct ("zombie") process

Example 1 shows all processes

Ps-a

Example 2 shows the process for the specified user

Ps-u Root

Example 3 shows all process information

Ps-ef

Example 4 output specified result

Ps-o Pid,ppid,pgrp,session,tpgid,comm

Reference Documentation:

Http://www.cnblogs.com/peida/archive/2012/12/19/2824418.html


Linux Command--ps command

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.