Project · Projects · System Analysis · UPDATES

10 Ways To Check Memory Usage In Linux


1. /proc/meminfo:

This is the simplest way to check the RAM usage on Linux. You can run ‘/proc/meminfo’ to check all the details related to RAM, it shows amount of free/available physical memory as well as the amount to buffer waiting or being written back to disk. /proc/meminfo gives all the required information about system memory usage.

2. atop:

This command is an interactive system and processes monitor for terminal environment, and it is based on ncurses. It shows updated information about system resources like CPU, memory, network, I/O and kernel. It also shows colored warnings in case of high system load. The command has top-like view of processes along with resource usage. System admin can easily read the summery and tell which process or user is responsible for system load. Reported memory statistics include total/free memory, cached/buffer memory and committed virtual memory.

3. free:

You can simply run this command to get the overview of memory usage obtained from /proc/meminfo. It shows total/free physical memory and swap space of the system. It also covers used/free buffer space in the kernel.

4. GNOME System Monitor:

This GUI application shows the short summery of system resource utilization for CPU, memory, swap space and network. The system monitor also offers process view of CPU and memory usage.

5. htop:

htop command is another interactive process viewer based ncurses. It shows all important memory usage statistics like total/free memory, total program size in memory, report resident memory size (RSS), shared page size, library size and even dirty page size of running processes.

6. KDE System Monitor:

KDE System Monitor is exclusively available for KDE based platforms. It functions almost same as GNOME system monitor. It shows real-time history of running processes and system resource usage. Users can view per process CPU/memory consumption.

7. memstat:

memstat utility is proven very useful to identify executable processes and shared libraries consuming virtual memory. It gives details like process ID, memstat also identifies the amount of virtual memory used by process associated executable, data and shared libraries.

8. nmon:

This system benchmark tool is based on ncurses. It can be used to monitor CPU, memory, disk I/O, kernel, filesystem and network resources in interactive mode. It also shows some important information like total/free memory, swap space, buffer/cached memory, virtual memory in/out statistics in real-time.

9. ps:

ps command is used to show per-process memory usage in real-time. The tool includes reported information like per cent of physical memory in use, total amount of virtual memory in use and amount of physical memory in use. You can even sort the information by using ‘—sort’ option.

10. smem:

You can categorise the memory usage according to different processes and user based informant using smem. This command uses proportional set size (PSS) metric to accurately measure memory usage of Linux processes. You can even generate the analyzed bar and pie graphs.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s