I am trying to create a small replica of the linux ps command using the c language. for example if my programs name is pps.C, when i call ./pps it would printout all the processes that the current user is running. I would like to know how to approach this so i can make it quick and short. 1. I would like to know how to find all the processes that the current user is running 2. how to print its running status, cmdline and such thanks

LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
5th Edition
ISBN:9781337569798
Author:ECKERT
Publisher:ECKERT
Chapter10: Common Administrative Tasks
Section: Chapter Questions
Problem 9HOP
icon
Related questions
Question
100%
Computer science
I am trying to create a small replica of the
linux ps command using the c language.
for example if my programs name is pps.c,
when i call ./pps it would printout all the
processes that the current user is running.
I would like to know how to approach this
so i can make it quick and short.
1. I would like to know how to find all the
processes that the current user is running
2. how to print its running status, cmdline
and such
thanks
Transcribed Image Text:I am trying to create a small replica of the linux ps command using the c language. for example if my programs name is pps.c, when i call ./pps it would printout all the processes that the current user is running. I would like to know how to approach this so i can make it quick and short. 1. I would like to know how to find all the processes that the current user is running 2. how to print its running status, cmdline and such thanks
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Linux
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
LINUX+ AND LPIC-1 GDE.TO LINUX CERTIF.
Computer Science
ISBN:
9781337569798
Author:
ECKERT
Publisher:
CENGAGE L