Wednesday 19 August 2020

RAM monitoring in AWS EC2

This post will answer the follow questions:

  1.  RAM brief intro
  2. How to get free RAM info of one system in browser using public ip?
  3. how free -m OS command output looks likes?
  4. How to get static information of RAM in browser?
  5. how to monitor RAM of the system with top command?

1.RAM(type,amount,generation):

    RAM is meant  as an "speed-up" in a computer.It is often used to store cache objects.

RAM gets emptied and lost at each machine's reboot.

Generally for Linux based OS command - top or "free -m "used to monitor the current amount of RAM being used.

if the RAM is not large enough, you will either get:

1.out of memory error.

2.The RAM will extend to the disk(which is way slower),it's called swapping.


when is RAM used?

Case study1: suppose your application is searching app in the pdf book.To speed up the search in the pdf book, need to move pdf book from disk to RAM. Bigger the book size,bigger the RAM required.

Case study 2: suppose your application is  performing simple multiplication 3*3 and the RAM utilization for simple multiplication is 10 MB. so for this case, if you increase the RAM their will be of no use.even after increasing the RAM only 10 MB of RAM is used.

--------------------------------------------------------------------------------------------------------------------------------------------------------------

2.How to get free RAM info of one system in browser using public ip.

To get the ram info of EC2 in browser:

<public_ip>:4567/ram/info

 

---------------------------------------------------------------------------------------------------------------------------------------------------------------


3.how free -m OS command output looks likes




   -----------------------------------------------------------------------------------------------------------------------------------------------


4.How to get static information of RAM in browser?

provide <public_ip>:4567/ram in the browser tab.

                                

5.how to monitor RAM of the system with top command?

  • output of top command looks like below screen:

  • press shift + f 
  • then the screen similar to the below will appears.
  • navigate to N and press enter.
           

the application based RAM utilization will appears



Conclusion: by this  top command RAM utilization of each application will get to know.based on that we will get to know how much RAM is required for our application. can also  extend RAM if our app requires by checking here.





No comments:

Post a Comment