AIX – Check Availiable Memory, Free Memory, and Used Memory in Gigabytes

Dunce-cap-2Dunce Cap… seriously is that a real thing. Have you or someone you know ever have had to wear one? Or is this just something made up for tv and movies… anyway I digress.

Everything is harder in AIX – like looking at memory statstics and viewing them in a normal human readable format (like gigabytes). Because apparently IBM knows best and like to show me free memory in 4k bytes (and filesystem sizes in 512-blocks).

Anyway while I was working on a production server with high memory usage found this nice little blog artice which contains a simple script for viewing availiable memory, free memory, and used memory in gigabtyes.

Link below:

And for my own selfish purposes I copied the script below — just in case the link above dies at somepoint.

memory=`prtconf -m | awk 'BEGIN {FS=" "} {print
usedmem=`svmon -G | grep memory | awk 'BEGIN {FS=" "} {print
freemem=`echo $memory-$usedmem | bc -l`

echo "Avai Mem: $memory GB"
echo "Free Mem: $freemem
echo "Used Mem: $usedmem GB"


Anyway.. AIX sucks and I hate it.


Related articles

New IBM servers meet Energy Star 2.0 guidelines
Sudosh Make Me a Sandwich: Install and Configure Sudosh in Solaris 9/10
IBM Power Systems with POWER7 and AIX & Linux Technical Sales Skills – v2 (000-225)