Thanks for your link,
Quote:
(Used – buffers – cached) / Total * 100 = % memory used
So you could get the following (expressed as Perl code):
my $memRealTotalOID = '.1.3.6.1.4.1.2021.4.5.0';
my $memRealAvailOID = '.1.3.6.1.4.1.2021.4.6.0';
my $memRealBuffersOID = '.1.3.6.1.4.1.2021.4.14.0';
my $memRealCachedOID = '.1.3.6.1.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
OR
Send traps for both, case closed!!