Home  >  Article  >  Operation and Maintenance  >  How to check the process through grep command under linux

How to check the process through grep command under linux

王林
王林Original
2020-06-01 08:59:255273browse

How to check the process through grep command under linux

Under normal circumstances, if we want to view some processes of Linux, it is natural to use the following command:

ps -ef | grep xxx

ps: process show display process

Parameters:

1, e Display all programs.

2. f Display UID, PPIP, C and STIME fields

grep: global search regular expression (RE) and print out the line Global regular expression matches and outputs.

The grep command is used to find strings that meet the conditions in the file.

Example:

In the current directory, find the file containing the test string in the file with the word file suffixed, and print out the line of the string. At this time, you can use the following command:

grep test *file

Recommended tutorial: linux tutorial

The above is the detailed content of How to check the process through grep command under linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn