Check Available Memory Slots Linux
Checking free memory slots left hi, I was just wondering is there any way one can check how many memory slots are unused in a HP server running HP UX 11i (rp5xxx,7xxx,8xxx and SD) without going all throught those calculations 'I have that much memory, my system can support up to that much memory - it means that I can add that much more memory'.
- Memory: 6156316k/7012352k available (4648k kernel code, 63836k reserved, 2402k data, 424k init, 5307208k highmem) The first part of the output is the value that you are looking for. The memory info is usually printed out in kB or kilo bytes.
- If you need memory totals, you can add the t option like so: free -mt. This will simply total the amount of memory in columns (Figure 5). Figure 5: Having free total your memory columns for you. Another very handy tool to have at your disposal is vmstat. This particular command is a one-trick pony that reports virtual memory statistics.
|
If you need a quick way to find out how much RAM your Linux system supports or to determine the number of DIMM slots available, you can use a command line tool called 'dmidecode'.
To find out the maximum RAM capacity and the number of RAM slots available, use the following command:
The output should look something like this:
The 'Maximum Capacity' is the maximum RAM supported by your system, while 'Number of Devices' is the number of memory (DIMM) slots available on your computer.
To see complete memory information, including the info above along with currently installed memory information (RAM speed, size, etc.), use:
Here's an example output for the command above:
You can also use lshw (among others) for this (firstly, install it; in Ubuntu: 'sudo apt-get install lshw):
It's important to note that Dmidecode reports system hardware information as described in the BIOS and does not scan your hardware, so in some cases the output can be wrong. Running dmidecode on my Dell XPS L702X non-3D laptop, the output says my system should have 4 RAM slots but in fact there are only 2 and only the 3D version of my laptop can have 4 RAM slots (and by the way, there are some Windows applications reporting the same thing), however, the command is accurate about it supporting 16 GB of RAM.