Thanks for your link,
(Used – buffers – cached) / Total * 100 = % memory used
So you could get the following (expressed as Perl code):
my $memRealTotalOID = '.126.96.36.199.4.1.2021.4.5.0';
my $memRealAvailOID = '.188.8.131.52.4.1.2021.4.6.0';
my $memRealBuffersOID = '.184.108.40.206.4.1.2021.4.14.0';
my $memRealCachedOID = '.220.127.116.11.4.1.2021.4.15.0';
# Memory Calculations
my $memRealUsed = $memRealTotal - $memRealAvail;
Then you can alert on % RAM used:
my $realPercent = (($memRealUsed - $memRealBuffers - $memRealCached )/ $memRealTotal) * 100;
This is fine to alert real/physical used memory percentage but if i am not mistaken mostly systems are designed to send traps for memTotalFree. why? any special reason/industry practice?
There are some debates, which is best practice to alert for memory? memTotalFree or RealFree
Send traps for both, case closed!!