Advertisement
Guest User

gavunixlab10

a guest
Jul 22nd, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.07 KB | None | 0 0
  1. For this lab assignment, we will write a system report similar to the one in the book. Before we begin, check to see if your linux installation has the vmstat command installed. If not install it using the following command
  2.  
  3. apt-get install sysstat
  4.  
  5. Once you have this tool installed you can start creating your script.
  6.  
  7. Copy the report format from the book. The only difference with your lab is the functions that we will use to generate this report.
  8.  
  9. Your report must include the following functions
  10.  
  11. Using the iostat command show ONLY CPU statistics
  12. iostat -c
  13. Using the iostat command show ONLY SDA statistics
  14. iostat -p sda
  15. Using the mvstat command show Active and Inactive memory statistics
  16. mvstat -a
  17. Using the ps command, show the programs with high memory consumption in the system
  18. ps -eo pid,ppid,cmd,%mem,%cpu --sort=-%mem | head
  19. Using the ps command, show the programs with high CPU consumption in the system
  20. ps -eo pid,ppid,cmd,%mem,%cpu --sort=-%cpu| head
  21. Deliverable
  22. Yuo will upload two files to iLearn.
  23.  
  24. source code file
  25. HTML report generated by your script
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement