The server is running oracle virtualization.
Existing RAM :
RAM SLOTS occupied /Total RAM SLOTS
RAM Size Each
4*24 = 96 GB.
Its easier to validate all the above information by opening up the physical server and examining ram slots.
However In production environment you hardly get any downtime so question of opening physical server has its own disadvantages.
The only option left is to Gather all the information from operating system itself.
Here is how i gathered the information.
# free -m
total used free shared buffers cached
Mem: 2048 2026 21 0 43 1693
-/+ buffers/cache: 290 1757
Swap: 10236 0 10236
# cat /proc/meminfo | grep Mem
MemTotal: 2097152 kB
MemFree: 30884 kB
Both the above statements only returned RAM size allocated to Dom-0 (Which is only 2 GB) and not the actual physical RAM.
To check the actual physical RAM i needed to run
# xm info | grep mem
total_memory : 98294
free_memory : 4276
node_to_memory : node0:4276
Which returned me the actual physical memory which is 96 GB.
Its time to explore deep into RAM allocation.i.e. to determine
How many RAMs are used?
What RAM size allocated for each slot?(As the server is capable of holding 2 GB, 4 GB, or 8 GB DDR3 ECC Registered DIMMs)
One tool that helps in determining all these without going into BIOS is dmidecode .
Fired following command to get the memory related information.
# dmidecode -t memory
It listed a huge output.
With little bit of grep i managed to get most out of the output.
1) Determine How many Memory Slots are available.
# dmidecode -t memory | grep "Bank Locator" | wc -l
Sets of physical memory modules may also be referred to as memory banks.