Skip to content

Commit

Permalink
Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
viveksanagari committed Jul 5, 2018
1 parent 4a773f1 commit fa5c145
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,8 @@

'cpu_host' can monitor the cpu usage of the host-machine/virtual-machine. It makes use of /proc/stat command for 60 seconds and redirect the command output to a text file. Then sum the required column values from the text file using ’awk’ command and calculate the cpu utilization (%) per minute.

'cpu_host_process' can monitor the cpu usage of a process running on a host-machine/virtual-machine. The script is written to monitor the cpu usage of the Virtual Box VM process running on host. It makes use of /proc/<\pid of the process>/stat for 60 seconds and redirect the command output to a text file. Then sum the required column values from the text file using ’awk’ command and calculate the cpu utilization (%) per minute. U_server_5 is the Virtual Box process name, for which the cpu utilization (%) per minute is desired to calculate. vbox.txt is the file name to which the output is redirected.
'cpu_host_process' can monitor the cpu usage of a process running on a host-machine/virtual-machine. The script is written to monitor the cpu usage of the Virtual Box VM process running on host. It makes use of /proc/(pid of the process)/stat for 60 seconds and redirect the command output to a text file. Then sum the required column values from the text file using ’awk’ command and calculate the cpu utilization (%) per minute. U_server_5 is the Virtual Box process name, for which the cpu utilization (%) per minute is desired to calculate. vbox.txt is the file name to which the output is redirected.
Note: Change the name U_server_5 to the process which the cpu utilization (%) per minute is desired to calculate. However, changing the file name vbox.txt is optional.

The scripts are written to estimate the utilization of cpu and memory till 60 seconds. However, the number of seconds can be scaled in the 'for' loops by editing its condition to: for value in {2..(mention the number of seconds)}.

0 comments on commit fa5c145

Please sign in to comment.