

{"id":110114,"date":"2022-07-18T16:00:50","date_gmt":"2022-07-18T10:30:50","guid":{"rendered":"https:\/\/data-flair.training\/blogs\/?p=110114"},"modified":"2022-07-18T16:17:12","modified_gmt":"2022-07-18T10:47:12","slug":"ps-command-in-linux","status":"publish","type":"post","link":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/","title":{"rendered":"PS Command in Linux"},"content":{"rendered":"<p>In this article, you will learn all there is to the ps command in Linux-based operating systems. We will go through what the ps command is, why it is used, and the names of the columns on output. We will also be going technical as we cover the syntax and options of the ps command. So sit down, grab a drink, buckle up and read right till the end!<\/p>\n<h3>What is Linux ps command?<\/h3>\n<p>Ps is an abbreviation for \u201cProcess Status\u201d. It is a command-line-based utility in Linux-based operating systems that helps in viewing information regarding a selection of running processes on a system.<\/p>\n<p>We all know by now that multitasking is one of the most distinguishing features of Linux distribution, Linux has the capability to handle multiple tasks simultaneously without interfering with one another. Just to get the basics straight, a process is the executing instance of any application or program in the operating system.<\/p>\n<p>The ps command lists all the currently running processes along with some additional information like PID (Process Identity), TTY, user ID, command name, how much space it occupies in the CPU, and many other things based upon the options we use.<\/p>\n<h3>How does the ps command work in Linux?<\/h3>\n<p>If you have been following along with our Linux articles you will also know that all the information about processes is stored in the \u201cproc\u201d directory in the Linux file system.<\/p>\n<p>When we invoke the ps command, it read the process information from the \u201c\/proc\u201d directory. The proc directory is also called the virtual file system because it contains virtual files.<\/p>\n<h3>Syntax of Linux ps command<\/h3>\n<p>The syntax of the pc command is very simple:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps &lt;options&gt;<\/pre>\n<h3>Understanding the output of linux ps command<\/h3>\n<p>Since all the commands of ps are used with options, let us see what happens when we simply run the ps command with no options at all.<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/understanding-the-output-of-the-ps-command.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110206\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/understanding-the-output-of-the-ps-command.webp\" alt=\"understanding the output of the ps command\" width=\"372\" height=\"126\" \/><\/a><\/p>\n<p>As you can see, in the above output there are 4 columns with different names, let us look at what they stand for before we talk about the option sued with the ps command.<\/p>\n<h4>1. PID<\/h4>\n<p>This column tells the Process identity of the running command.<\/p>\n<h4>2. TTY<\/h4>\n<p>This column tells the type of terminal the command is running on.<\/p>\n<h4>3. TIME<\/h4>\n<p>This column tells how much time of the CPU was taken by the command<\/p>\n<h4>4. CMD<\/h4>\n<p>This column tells the name of the command.<\/p>\n<h3>Options used with the ps command in Linux<\/h3>\n<p>In the syntax of the ps command, there is a field for entering options that take in a range of available options which specify how the ps command should work and how the output should be formatted. Let us take a look at some of the available options of the ps command:<\/p>\n<h4>1. -ax<\/h4>\n<p>This option lists all the currently running processes.<\/p>\n<h4>2. -ef<\/h4>\n<p>This option lists the currently running processes in full format.<\/p>\n<h4>3. -u &lt;username&gt;<\/h4>\n<p>This option lists the process for the user that you specified.<\/p>\n<h4>5. -C &lt;command&gt;<\/h4>\n<p>This option lists the process for the command you specified.<\/p>\n<h4>6. -p&lt;PID&gt;<\/h4>\n<p>This option lists the processes with the (PID) process identity you specified.<\/p>\n<h4>7. -ppid &lt;PPID&gt;<\/h4>\n<p>This option lists the processes with the PPID you specified.<\/p>\n<h4>8. Pstree<\/h4>\n<p>This option shows the process in the hierarchy.<\/p>\n<h4>9. -L<\/h4>\n<p>This option lists all the threads for a particular process.<\/p>\n<h4>10. &#8211;sort pmem<\/h4>\n<p>This option finds the memory leak if there is any.<\/p>\n<h4>11. -eo<\/h4>\n<p>This option shows the security information.<\/p>\n<h4>12. -U root -u root<\/h4>\n<p>This option shows the process running by the root.<\/p>\n<p>Now that we have laid down the fundamentals, let us look at 20 beautiful practical commands of ps in the terminal.<\/p>\n<h3>Listing all the processes in the current shell<\/h3>\n<p>If you want to display all the processes for the current shell, run the ps command with no options at all.<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/listing-all-the-processes-in-the-current-shell.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110207\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/listing-all-the-processes-in-the-current-shell.webp\" alt=\"listing all the processes in the current shell\" width=\"480\" height=\"161\" \/><\/a><\/p>\n<h3>Printing all processes in different formats<\/h3>\n<p>If you want to display every single active process on a Linux system in the generic Unix\/Linux format, you can either use the option \u201c-e\u201d or \u201c-a\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -e\u201d or \u201cps -a<\/pre>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-all-processes-in-different-formats.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110208\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-all-processes-in-different-formats.webp\" alt=\"printing all processes in different formats\" width=\"550\" height=\"896\" \/><\/a><\/p>\n<h3>Printing in BSD format<\/h3>\n<p>If you want to list all the currently running processes in BDS format, you can either use \u201cau\u201d or \u201caxu\u201d<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-in-bsd-format.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110209\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-in-bsd-format.webp\" alt=\"printing in bsd format\" width=\"886\" height=\"894\" \/><\/a><\/p>\n<h3>Printing in full format<\/h3>\n<p>If you want to print all the currently running processes in full format, combine the option \u201c-f\u201d with the option \u201c-e\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -ef<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-in-full-format.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110210\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-in-full-format.webp\" alt=\"printing in full format\" width=\"780\" height=\"407\" \/><\/a><\/h3>\n<h3>Displaying user running processes in Linux<\/h3>\n<h4>Displaying processes owned by you<\/h4>\n<p>To select all processes owned by you use the option \u201c-x\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -x<\/pre>\n<h4><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-user-running-processes.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110211\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-user-running-processes.webp\" alt=\"displaying user running processes\" width=\"780\" height=\"256\" \/><\/a><\/h4>\n<h4>Displaying processes of a specific user<\/h4>\n<p>If you want to display a user\u2019s processes by real user ID, use the option \u201c-U\u201d followed by the name of the user, as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -u&lt;username&gt;<\/pre>\n<h4><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-of-a-specific-user.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110212\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-of-a-specific-user.webp\" alt=\"displaying processes of a specific user\" width=\"780\" height=\"382\" \/><\/a><\/h4>\n<h4>Printing all processes running as root<\/h4>\n<p>If you want to list every process running with root user privileges (real &amp; effective ID) in user format, use the option \u201c-U root -u root\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -U root -u root<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-all-processes-running-as-root.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110213\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-all-processes-running-as-root.webp\" alt=\"printing all processes running as root\" width=\"682\" height=\"745\" \/><\/a><\/h3>\n<h3>Displaying group processes<\/h3>\n<p>To list all processes owned by a certain group (real group ID (RGID) or name), use the option \u201cG\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -fG &lt;group name&gt;<\/pre>\n<h3>Displaying processes by PID<\/h3>\n<p>To list processes by process identity use the option \u201c-p\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -fp &lt;PID&gt;<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-by-pid.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110214\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-by-pid.webp\" alt=\"displaying processes by pid\" width=\"780\" height=\"116\" \/><\/a><\/h3>\n<h3>Displaying processes by PPID<\/h3>\n<p>To list processes by parent process identity use the option \u201c&#8211;ppid\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -f--ppid &lt;PPID&gt;<\/pre>\n<h3>Displaying multiple processes by PID<\/h3>\n<p>If you want to display multiple processes by specifying their process identity, you can use the option \u201c-p\u201d followed by the process identities separated by a space, here is how:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -fp &lt;PID&gt; &lt;PID&gt; &lt;PID&gt;<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-multiple-processes-by-pid.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110215\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-multiple-processes-by-pid.webp\" alt=\"displaying multiple processes by pid\" width=\"780\" height=\"150\" \/><\/a><\/h3>\n<h3>Displaying processes by TTY<\/h3>\n<p>To list processes by TTY, use the option \u201c-t\u201d followed by the TTY value, as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -t &lt;TTY&gt;<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-by-tty.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110216\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-processes-by-tty.webp\" alt=\"displaying processes by tty\" width=\"568\" height=\"158\" \/><\/a><\/h3>\n<h3>Printing process tree<\/h3>\n<p>To show the process tree of the process, use the option \u201c&#8211;forest\u201d.<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-process-tree.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110218\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-process-tree.webp\" alt=\"printing process tree\" width=\"692\" height=\"876\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<h3>Printing process threads<\/h3>\n<p>To print all the threads of a process, use the option \u201c-l\u201d followed by the name of the process as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -fl -C &lt;process name&gt;<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-process-threads.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110217\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-process-threads.webp\" alt=\"printing process threads\" width=\"780\" height=\"121\" \/><\/a><\/h3>\n<h3>Listing all format specifiers<\/h3>\n<p>If you want to list all the format specifiers, use the option \u201cL\u201d<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/listing-all-format-specifiers.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110219\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/listing-all-format-specifiers.webp\" alt=\"listing all format specifiers\" width=\"258\" height=\"889\" \/><\/a><\/p>\n<h3>Printing only specific format specifiers<\/h3>\n<p>If you want to print the output in your own format, you can use the option \u201c-eo\u201d followed by the format specifier you want. For example, the command \u201cps -eo pid,ppid,user,tty, cmd\u201d will print only the columns PID, PPID, USER, TTY, and CMD<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-only-specific-format-specifiers.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110220\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-only-specific-format-specifiers.webp\" alt=\"printing only specific format specifiers\" width=\"672\" height=\"893\" \/><\/a><\/p>\n<h3>Finding a process name using its PID<\/h3>\n<p>If you want to display the name of a process using its PID, you can use the option \u201c-P\u201d followed by the PID and option \u201c-o\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -p &lt;PID&gt; -o comm=<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/finding-a-process-name-using-its-pid.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110221\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/finding-a-process-name-using-its-pid.webp\" alt=\"finding a process name using its pid\" width=\"568\" height=\"193\" \/><\/a><\/h3>\n<h3>Displaying parent and child processes<\/h3>\n<p>If we select a process by its name, it will automatically display its parent and child processes. To do the same make use of the option \u201c-C\u201d.<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-parent-and-child-processes.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110222\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/displaying-parent-and-child-processes.webp\" alt=\"displaying parent and child processes\" width=\"532\" height=\"237\" \/><\/a><\/p>\n<h3>Checking the execution time of a process<\/h3>\n<p>To check the execution time of a specific command, specify the \u201cetime\u201d format specifier and use the grep command to filter out the process you want. Use the command:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -eo comm,etime | grep &lt;process name&gt;<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/checking-the-execution-time-of-a-process.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110223\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/checking-the-execution-time-of-a-process.webp\" alt=\"checking the execution time of a process\" width=\"738\" height=\"165\" \/><\/a><\/h3>\n<h3>Printing security information<\/h3>\n<p>To show security context, use the option \u201c&#8211;context\u201d as shown:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">ps -e --context<\/pre>\n<h3><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-security-information.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-110224\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/printing-security-information.webp\" alt=\"printing security information\" width=\"780\" height=\"889\" \/><\/a><\/h3>\n<h3>Understanding the output<\/h3>\n<p>In all of the outputs we got till now there are many fields that are being displayed on the screen. Let us take a closer look at each of the fields:<\/p>\n<h4>1. UID<\/h4>\n<p>This field displays the User Identifictaiuon number of the user who started this process.<\/p>\n<h4>2. PID<\/h4>\n<p>This field displays the process identification number of the process<\/p>\n<h4>3. PPID<\/h4>\n<p>This field displays the identification number of the parent process, the parent process initiates a process.<\/p>\n<h4>4. C<\/h4>\n<p>This field displays the amount of CPU that this process is currently using.<\/p>\n<h4>5. STIME<\/h4>\n<p>This field displays the time the process was started on the current system.<\/p>\n<h4>6. TTY<\/h4>\n<p>This field displays the terminal that was used to start the process.<\/p>\n<h4>7. TIME<\/h4>\n<p>This field displays the amount of CPU time this process has consumed since it began running.<\/p>\n<h4>8. CMD<\/h4>\n<p>This field displays the command that was used to start this process.<\/p>\n<h4>9. SZ<\/h4>\n<p>This field displays the size in physical pages of the core image of the process.<\/p>\n<h4>10. RSS<\/h4>\n<p>This field displays the resident set size, which is the total amount of non-swapped physical memory used by the process.<\/p>\n<h4>11. PSR<\/h4>\n<p>This field displays the processor that this process is currently assigned to.<\/p>\n<h3>Summary<\/h3>\n<p>As you have seen, the ps command is a simple command that helps in the task of printing various different pieces of information about processes. You have now learned what the ps command is, why it is used, and the names of the columns on output.<\/p>\n<p>We have also gone technical by looking at the syntax, options, and 20 amazing practical examples of the ps command in the terminal.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this article, you will learn all there is to the ps command in Linux-based operating systems. We will go through what the ps command is, why it is used, and the names of&#46;&#46;&#46;<\/p>\n","protected":false},"author":5,"featured_media":110204,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[35],"tags":[27037],"class_list":["post-110114","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","tag-ps-command-in-linux"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.8 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>PS Command in Linux - DataFlair<\/title>\n<meta name=\"description\" content=\"Learn what linux ps command is, its syntax, examples, why it is used, and the names of the columns on output.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"PS Command in Linux - DataFlair\" \/>\n<meta property=\"og:description\" content=\"Learn what linux ps command is, its syntax, examples, why it is used, and the names of the columns on output.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/\" \/>\n<meta property=\"og:site_name\" content=\"DataFlair\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/DataFlairWS\/\" \/>\n<meta property=\"article:published_time\" content=\"2022-07-18T10:30:50+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-07-18T10:47:12+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"628\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/webp\" \/>\n<meta name=\"author\" content=\"DataFlair Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:site\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"DataFlair Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"11 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"PS Command in Linux - DataFlair","description":"Learn what linux ps command is, its syntax, examples, why it is used, and the names of the columns on output.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/","og_locale":"en_US","og_type":"article","og_title":"PS Command in Linux - DataFlair","og_description":"Learn what linux ps command is, its syntax, examples, why it is used, and the names of the columns on output.","og_url":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/","og_site_name":"DataFlair","article_publisher":"https:\/\/www.facebook.com\/DataFlairWS\/","article_published_time":"2022-07-18T10:30:50+00:00","article_modified_time":"2022-07-18T10:47:12+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp","type":"image\/webp"}],"author":"DataFlair Team","twitter_card":"summary_large_image","twitter_creator":"@DataFlairWS","twitter_site":"@DataFlairWS","twitter_misc":{"Written by":"DataFlair Team","Est. reading time":"11 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#article","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/"},"author":{"name":"DataFlair Team","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/7f83c342f5d1632d6f7b4b0b0f447823"},"headline":"PS Command in Linux","datePublished":"2022-07-18T10:30:50+00:00","dateModified":"2022-07-18T10:47:12+00:00","mainEntityOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/"},"wordCount":1419,"commentCount":0,"publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp","keywords":["PS Command in Linux"],"articleSection":["Linux Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/","url":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/","name":"PS Command in Linux - DataFlair","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/#website"},"primaryImageOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#primaryimage"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp","datePublished":"2022-07-18T10:30:50+00:00","dateModified":"2022-07-18T10:47:12+00:00","description":"Learn what linux ps command is, its syntax, examples, why it is used, and the names of the columns on output.","breadcrumb":{"@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#primaryimage","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2022\/05\/ps-command-in-linux.webp","width":1200,"height":628,"caption":"ps command in linux"},{"@type":"BreadcrumbList","@id":"https:\/\/data-flair.training\/blogs\/ps-command-in-linux\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog Home","item":"https:\/\/data-flair.training\/blogs\/"},{"@type":"ListItem","position":2,"name":"Linux Tutorials","item":"https:\/\/data-flair.training\/blogs\/category\/linux\/"},{"@type":"ListItem","position":3,"name":"PS Command in Linux"}]},{"@type":"WebSite","@id":"https:\/\/data-flair.training\/blogs\/#website","url":"https:\/\/data-flair.training\/blogs\/","name":"DataFlair","description":"Learn Today. Lead Tomorrow.","publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/data-flair.training\/blogs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/data-flair.training\/blogs\/#organization","name":"DataFlair","url":"https:\/\/data-flair.training\/blogs\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","width":106,"height":48,"caption":"DataFlair"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/DataFlairWS\/","https:\/\/x.com\/DataFlairWS","https:\/\/www.linkedin.com\/company\/dataflair-web-services-pvt-ltd\/","https:\/\/www.youtube.com\/user\/DataFlairWS"]},{"@type":"Person","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/7f83c342f5d1632d6f7b4b0b0f447823","name":"DataFlair Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","caption":"DataFlair Team"},"description":"DataFlair Team creates expert-level guides on programming, Java, Python, C++, DSA, AI, ML, data Science, Android, Flutter, MERN, Web Development, and technology. Our goal is to empower learners with easy-to-understand content. Explore our resources for career growth and practical learning.","url":"https:\/\/data-flair.training\/blogs\/author\/dfteam1\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/110114","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/comments?post=110114"}],"version-history":[{"count":3,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/110114\/revisions"}],"predecessor-version":[{"id":110225,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/110114\/revisions\/110225"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media\/110204"}],"wp:attachment":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media?parent=110114"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/categories?post=110114"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/tags?post=110114"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}