Language Selection

English French German Italian Portuguese Spanish

How to measure memory usage in Linux

Filed under
Software
HowTos

Whether you are a system administrator or a developer, sometimes you need to consider the use of memory in GNU/Linux processes and programs. Memory is a critical resource, and limited memory plus processes that use a lot of RAM can cause a situation where the kernel goes out of memory (OOM). In this state Linux activates an OOM killer kernel process that attempts to recover the system by terminating one or more low-priority processes. Which processes the system kills is unpredictable, so though the OOM killer may keep the server from going down, it can cause problems in the delivery of services that should stay running.

In this article we'll look at three utilities that report information about the memory used on a GNU/Linux system. Each has strengths and weaknesses, with accuracy being their Achilles' heel. I'll use CentOS 6.4 as my demo system, but these programs are available on any Linux distribution.

rest here




More in Tux Machines

GNOME News

  • Do you like Windows 10 Look but Love LINUX? Here are Windows 10 GTK Themes for you!
  • A history about Gtk+, Vulkan and Wayland
    A few weeks ago, I was curious to test Gtk+ 4. I know it has some awsome features like OpenGL rendering, major cleanups and other hot stuff, but didn’t have the chance to check it out until then. I was mostly excited about Vulkan. I know both of my laptop’s graphic cards support Vulkan. It’s a hybrid Intel Broadwell G2 + NVidia GeForce 920M, although I don’t use the latter because Linux sucks hard with Dual GPU. Downloaded the latest Gtk+ source, compiled and… nothing. Immediate segmentation fault. Yay! What a great chance to get involved with the next major Gtk+ version development!
  • GNOME Developer On GTK4: State-of-the-Art of Toolkit Support
    GNOME developer Georges Stavracas has shared his thoughts on the state of the GTK4 tool-kit with the recent work involving a Vulkan renderer, including which also now works on Wayland. Georges Stavracas was excited to try the current state of GTK4 development but initially hit a segmentation fault. But after overcoming that, he was successful in running GTK4 on Wayland and the widgets being rendered by Vulkan. He commented on his blog, "May not be as exciting, since there are no new visible features but… damn, it’s Gtk+ being rendered with Vulkan on Wayland. It’s basically the state-of-the-art of toolkit support right now. Even better, the absolute majority of applications will gain this for free once they port to Gtk+ 4 series."

Red Hat and Fedora

Leftovers: Ubuntu

Android Leftovers