Memory Usage with MRTG

Taking care of your Linux box.

Memory Usage with MRTG

Postby rmuhammadali » Wed Dec 16, 2009 4:50 pm

Dear All,
I am trying to configure MRTG to calculate my system memory usage, i have wrote the following syntex. It makes the reporting graph but there is no update show in it.

Target[LocalMem]: memTotalReal.0&memTotalReal.0:public@localhost + memAvailReal.0&memAvailReal.0:public@localhost + memTotalFree.0&memTotalFree.0:public@localhost
Options[LocalMem]: nopercent, growright, unknaszero
Title[LocalMem]: Physical Memory Usage Graph
PageTop[LocalMem]: <h1>Physical Memory Usage Graph</h1>
MaxBytes[LocalMem]: 536870912
YLegend[LocalMem]: Memory Usage
UnScaled[LocalMem]: ymwd

Please help!

Regards
Ali
rmuhammadali
Cadet
 
Posts: 5
Joined: Wed Oct 07, 2009 1:17 pm
WLM: rmuhammadali@hotmail.com
Location: Faislabad - Pakistan

Postby zaib » Fri Jan 15, 2010 1:36 pm

Have you properly configured SNMP on your *nix box ? can you snmpwalk to your required OID ?

BTW, following are my Memory monitoring Scripts for MRTG.

==========================================

Code: Select all

# Memory Monitoring (Total Versus Available Memory in KB)
Target[gw.memory]: memAvailReal.0&memTotalReal.0:public@localhost
Title[gw.memory]: LINUX GW Free Memory in MBytes
PageTop[gw.memory]: <H1>LINUX GW Free Memory in Bytes</H1>
MaxBytes[gw.memory]: 100000000000000
ShortLegend[gw.memory]: B
YLegend[gw.memory]: MB
LegendI[gw.memory]: Free
LegendO[gw.memory]: Total
Legend1[gw.memory]: Free memory
Legend2[gw.memory]: LINUX GW Total memory
Options[gw.memory]: gauge,growright,nopercent
kMG[gw.memory]: k,M,G,T,P,X

# Memory Monitoring (Percentage usage)
Title[gw.mempercent]: LINUX GW Percentage Memory Free in (%)
PageTop[gw.mempercent]: <H1>LINUX GW Percentage Free Memory</H1>
Target[gw.mempercent]: ( memAvailReal.0&memAvailReal.0:public@localhost ) * 100 / ( memTotalReal.0&memTotalReal.0:public@loca$
options[gw.mempercent]: growright, gauge, nopercent, integer
Unscaled[gw.mempercent]: ymwd
MaxBytes[gw.mempercent]: 100
YLegend[gw.mempercent]: Memory %
ShortLegend[gw.mempercent]: Percent
LegendI[gw.mempercent]: Free
LegendO[gw.mempercent]:
Legend1[gw.mempercent]: LINUX GW Percentage Free Memory
Legend2[gw.mempercent]:

==========================================

Result of above MRTG Memory Script is as follows.

Image

Image
Regards,

SYED JAHANZAiB

web: http://aacable.wordpress.com
msn: aacable@hotmail.com
zaib
Naik
 
Posts: 97
Joined: Thu Jan 10, 2008 3:11 pm
Website: http://aacable.wordpress.com
WLM: aacable@hotmail.com
Yahoo Messenger: johny_reico@yahoo.com
Location: Karachi


Return to “%s” Administration

Who is online

Users browsing this forum: No registered users and 1 guest

cron