Knowledge Base Hub

Browse through our helpful how-to guides to get the fastest solutions to your technical issues.

Home  >  DigitalOcean  >  How to Install htop to Check the Droplet’s Memory Usage?
Top Scroll

How to Install htop to Check the Droplet’s Memory Usage?

 2 min

To check the droplet’s memory usage you will need to install htop process monitoring tool.

Installation of htop on Ubuntu

1. Login to your server.

2. Execute the below command:

sudo apt-get install htop

This will help you to know which programs are consuming more RAM.

3. You will see the memory usage in htop just below the CPU statistics. Memory monitoring is displayed in the form of progress bars with multiple colors.

  • Green: It is the percentage of RAM consumed by memory pages.
  • Blue: It is the percentage of RAM consumed by buffer pages.
  • Orange: It is the percentage of RAM consumed by cache pages.

4. Below is the detailed process information in htop about memory:

  • VIR – It indicates the virtual memory that a process is consuming.
  • RES – It indicates the physical memory that a process is consuming.
  • SHR – It indicates the shared memory that a process is consuming.
  • MEM% – It indicates the percentage of memory consumed by each process.

5. You can check the memory consumption using the shortcut key ‘M’.

Installation of htop on CentOS

You can install htop on CentOS using yum.

1. Execute below command to add EPEL repository to the yum package manager:

yum -y install epel-release
yum -y update

2. After adding the repository, you can ask yum to install the htop process monitoring tool:

yum -y install htop

3. If the installation is done successfully, you should be able to type htop in the command line and view the status of your system.

In this way you can install htop process monitoring tool on Ubuntu and CentOS to check your droplet’e memory usage.

For our Knowledge Base visitors only
Get 10% OFF on Hosting
Special Offer!
30
MINS
59
SECS
Claim the discount before it’s too late. Use the coupon code:
STORYSAVER
Note: Copy the coupon code and apply it on checkout.