Display a list of process currently running on the computer
$30-120 USD
Completed
Posted over 22 years ago
$30-120 USD
Paid on delivery
The Unix command ps -ef displays a list of the processes currently running on the computer. The task of this assignment is to write a filter which takes, as its input, the piped output of the above command and summarises the running processes. Firstly familiarise yourself with the output generated by the above command. In particular, note the header (to be ignored), the two different formats for the start time (hours:mins:secs or a date), the existence of defunct processes (also to be ignored) and the form of the executing program. Note also the format of the elapsed CPU time. Write a C++ program [login to view URL] to read the above input, extracting the login name, the elapsed CPU time and the name of the program that is running (not including options and arguments). Note also that programs with full pathnames may include /../ in their path. This should be removed, along with what precedes it, so that the pathname is still correct. All other fields should not be stored. You may assume that the program's name does not include a space. Add code to determine the process that has the longest elapsed CPU time, listing both the login name and the program name. Similarly determine the program which is the deepest in the file tree. Finally, for each login name, count the number of processes running and the total elapsed CPU time for all their processes. This will involve creating a simple linked list to hold the login name, number of processes encountered so far, and the accumulated CPU time. A stack access method will do, as the logins will not be sorted. Once the end-of-file has been encountered, print a table. Requirements
## Deliverables
Complete source code of all programming work done
## Deadline information
i need this with in 3 days