Script to show Total, Free and Used Memory on AIX

Just Copy and Paste:

(memory=`prtconf -m | awk 'BEGIN {FS=" "} {print $3/1024}'`
usedmem=`svmon -G | grep memory | awk 'BEGIN {FS=" "} {print $3/256/1024}'`
freemem=`echo $memory-$usedmem | bc -l`
clear
echo
echo "Memory Results:"
echo "----------------------"
echo
echo "Avai Mem: $memory GB"
echo "Free Mem: $freemem GB"
echo "Used Mem: $usedmem GB"
echo
echo)

Result:

Memory Results:
----------------------

Avai Mem: 2 GB
Free Mem: 0.69649 GB
Used Mem: 1.30351 GB
0 (0)
Article Rating (No Votes)
Rate this article
Attachments
There are no attachments for this article.
Comments
There are no comments for this article. Be the first to post a comment.
Full Name
Email Address
Security Code Security Code
Related Articles RSS Feed
LVM: Shrink & extend a filesystem/volume
Viewed 3049 times since Sun, Jun 3, 2018
The new VIOS performance advisor tool part util
Viewed 4449 times since Tue, Jun 4, 2019
How to check dual path in AIX
Viewed 16120 times since Fri, Jun 8, 2018
This document discusses a new feature implemented for JFS2 filesystems to prevent simultaneous mounting.
Viewed 5700 times since Sat, Jun 1, 2019
AIX NFS Version 4 configuration over Kerberos inter-realm setup
Viewed 5842 times since Wed, Jun 27, 2018
AIX POWERHA/HACMP: Basic commands
Viewed 7077 times since Sat, Jun 2, 2018
AIX - How to get Memory infomation
Viewed 14524 times since Fri, Jun 8, 2018
A Change to the SMT Mode Default in POWER9
Viewed 7049 times since Fri, Jan 18, 2019
http://ibmsystemsmag.com/aix/administrator/backuprecovery/remote-sync/
Viewed 6377 times since Wed, May 30, 2018
How To Mirror Your Root Disk On AIX (a.k.a. rootvg)
Viewed 7772 times since Mon, May 21, 2018