Question

Hide Assignment Information Instructions Instructions for Lab 6 First, a little review on processes How to...

Hide Assignment Information

Instructions

Instructions for Lab 6

First, a little review on processes

How to view processes (6 minutes)

On the top of all your documents, always include these items:

your name:
date:
Lab number

Repeat the process that you used to save the log file that will be produced by this lab. You can either use the log feature on putty or the script command at the shell prompt.

Login to our system and follow these steps while recording your session. Once your session has been recorded. Open your file and next to command prompt, describe what you just have done. i.e. :

wmorales@syccuxfs01:~> ps                 << this command shows the running processes

PID TTY         TIME CMD
1257 pts/5   00:00:00 bash
1596 pts/5   00:00:00 ps

wmorales@syccuxas01:~>

Upload your .txt file to the dropbox. Remember the format:

Question: in this case the command used, then explain what the command does, then

a partial output (using the log feature) of the command. Just like the above example.

use ----------- cut ---------- if the output is too long.

>>>>>>>>>>>>>>>> start here <<<<<<<<<<<<<<<<<

$ ps ax

$ ps –ef

$ ps aux

$ps –ef f

$ ps -f -u wmorales <<< it can be user userid

$ ps aux --sort=-pcpu,+pmem

$ ps aux --sort=-pcpu | head -5

$ ps -f --forest

$ ps -e -o pid,uname,pcpu,pmem,comm

$ ps -e -o pid,uname=USERNAME,pcpu=CPU_USAGE,pmem,comm

$ ps -e -o pid,comm,etime

$ watch -n 1 'ps -e -o pid,uname,cmd,pmem,pcpu --sort=-pmem,-pcpu | head -15'

0 0
Add a comment Improve this question Transcribed image text
Answer #1

ps ax
********

Select all processes except both session leaders with Lift the BSD-style "must have a tty" restriction.

ubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal 2 Fri 12:01

ps ef
********

-e flag to print all the processes within the system see a more detailed output by using the -f option

ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities - Terminal 2 Fri 12:03

ps aux
***********

Х 2 OX Hubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal Fri

ps –ef f
**********

ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal 2 Fri 12:05 m

ps -f -u <username>
************************

PID 1472 1 Hubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal

ps aux --sort=-pcpu,+pmem
********************************

show all user's process with sort via process cpu and process memory

1708 0.1 Hubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities - Terminal

ps aux --sort=-pcpu | head -5
**************************************

will show only top 5 processes

ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities - Terminal - 2 Fri 12:

ps -f --forest
*****************

2 OX ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities - Terminal - Fri

ps -e -o pid,uname,pcpu,pmem,comm
**********************************************

ubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal Fri 12:08 ma

ps -e -o pid,uname=USERNAME,pcpu=CPU_USAGE,pmem,comm
******************************************************************************

sort by username and cpu usage with ascending order of processes

2 OX ubuntu 18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal Fri 12:

ps -e -o pid,comm,etime
*******************************

since process started show by elpsed time column

ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal 2 Fri 12:09 m

watch -n 1 'ps -e -o pid,uname,cmd,pmem,pcpu --sort=-pmem,-pcpu | head -15'
*********************************************************************************************

sort by process with each process time interval changes of 1 sec

ubuntu18 (Snapshot 1) [Running] - Oracle VM VirtualBox File Machine View Input Devices Help Activities Terminal Fri 12:11 mad


if you have any doubt then please ask me without any hesitation in the comment section below , if you like my answer then please thumbs up for the answer , before giving thumbs down please discuss the question it may possible that we may understand the question different way and i can edit and change the answers if you argue, thanks :)

Add a comment
Know the answer?
Add Answer to:
Hide Assignment Information Instructions Instructions for Lab 6 First, a little review on processes How to...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT