Random Access Memory (RAM) is the memory in the computer that is used to store running process and data. RAM provides faster data access as compared to the disk drive. This page shows how to find out the amount of free and used memory in the Debian Linux system.
Check memory Debian Linux
The procedure to check memory is as follows:
- Open the terminal app or login to the remote Debian server using ssh command:
- Type the free command to see memory in mebibytes:
- You can also /proc/meminfo:
Let us see all commands to check memory usage on Debian Linux cloud or bare metal server.
1. free command
Display the amount of memory in bytes:
Show the amount of memory in mebibytes:
Get the amount of memory in megabytes:
Find the amount of memory in gibibyte:
Want to see the amount of memory in gigabytes? Pass --giga option as follows:
Pass the -t option to get totals info about memory:
free --giga -t
Use cat command as follows:
3. top command
Just type top command:
4. vmstat command
To get report about virtual memory statistics on Debian Linux, run:
vmstat 2 5
Understanding memory output of vmstat
- swpd: the amount of virtual memory used.
- free: the amount of idle memory.
- buff: the amount of memory used as buffers.
- cache: the amount of memory used as cache.
- inact: the amount of inactive memory. (-a option)
- active: the amount of active memory. (-a option)