Habe ein Problem mit MRTG. Ich habe den gestern "frisch" installiert, mit SNMP, und komischereise sehe ich wie MRTG selber seitdem langsam aber sicher den gesamten Speicher aufbraucht (so eine richtig schön steigende Kurve, fast wie ein typischer Börsenkurs vor 4 Jahren ;-))
hier mal die Ausgabe aus top:
Code: Select all
11321 root 9 0 279m 83m 2788 S 0.0 34.5 23:23.15 mrtg
MRTG läuft als Dämon, ich denke wenn ich es als cron laufen lassen würde, wäre das Problem erledigt, aber ich hatte es auch früher schon ohne jegliche Probleme als Dämon laufen lassen. Eigentlich wäre mir der Dämon lieber. Ich verwende Version 2.10.14.
Könnte es an der Konfiguration liegen?
Code: Select all
# Created by
# /usr/bin/cfgmaker --global 'WorkDir: /var/www/admin/htdocs/mrtg' --global 'Options[_]: growright' --output /etc/mrtg.conf --ifref=ip xxx@127.0.0.1
### Global Config Options
RunAsDaemon: Yes
Interval:5
Language: german
EnableIPv6: no
WorkDir: /var/www/admin/htdocs/mrtg
Options[_]: growright
background[_]: #eeeeee
XScale[_]: 1.0
YScale[_]: 1.5
XSize[_]: 600
YSize[_]: 150
### Interface 3 >> Descr: 'eth0' | Name: '' | Ip: 'xxx.xxx.xxx.xxx' | Eth: 'xx-xx-xx-xx-xx-xx' ###
Target[127.0.0.1_xxx.xxx.xxx.xxx]: /xxx.xxx.xxx.xxx:xxx@127.0.0.1:
SetEnv[127.0.0.1_xxx.xxx.xxx.xxx]: MRTG_INT_IP="xxx.xxx.xxx.xxx" MRTG_INT_DESCR="eth0"
MaxBytes[127.0.0.1_xxx.xxx.xxx.xxx]: 12500000
Title[127.0.0.1_xxx.xxx.xxx.xxx]: Traffic Analysis for xxx.xxx.xxx.xxx --
PageTop[127.0.0.1_xxx.xxx.xxx.xxx]: <H1>Traffic Analysis for xxx.xxx.xxx.xxx -- </H1>
Title[ps0]: Anzahl Prozesse gesamt/Apache (ps)
MaxBytes[ps0]: 2000
ShortLegend[ps0]: proc
YLegend[ps0]: proc
Legend1[ps0]: proc
Target[ps0]: `ps ax | grep -c 'apache' && ps ax | grep -cvE '[0-9] ('`
LegendI[ps0]: apache
LegendO[ps0]: gesamt
WithPeak[ps0]: ymwd
Options[ps0]: gauge,growright
PageTop[ps0]: <h1>Anzahl Prozesse gesamt/Apache</h1>
Title[ps1]: Anzahl Prozesse gesamt/Mysqld (ps)
MaxBytes[ps1]: 2000
ShortLegend[ps1]: proc
YLegend[ps1]: proc
Legend1[ps1]: proc
Target[ps1]: `ps ax | grep -c 'mysqld' && ps ax | grep -cvE '[0-9] ('`
LegendI[ps1]: mysqld
LegendO[ps1]: gesamt
WithPeak[ps1]: ymwd
Options[ps1]: gauge,growright
PageTop[ps1]: <h1>Anzahl Prozesse gesamt/Mysqld</h1>
Title[vmstat1]: Prozessor-Auslastung (gesamt/system)
MaxBytes[vmstat1]: 100
ShortLegend[vmstat1]: %
YLegend[vmstat1]: %
Legend1[vmstat1]: %
Target[vmstat1]: `vmstat 1 2 | tail -n 1 | awk '{printf("%dn%dn",$14,100-$15)}'`
LegendI[vmstat1]: system
LegendO[vmstat1]: gesamt
WithPeak[vmstat1]: ymwd
Options[vmstat1]: gauge,growright
PageTop[vmstat1]: <h1>Prozessor-Auslastung (gesamt/system)</h1>
Title[vmstat2]: Speicher-Auslastung (swap/free)
MaxBytes1[vmstat2]: 536870912
MaxBytes2[vmstat2]: 268435456
ShortLegend[vmstat2]: MB
YLegend[vmstat2]: MB
Legend1[vmstat2]: MB
Target[vmstat2]: `vmstat |awk '/ [0-9] / {printf("%fn%fn",$3/1024,$4/1024)}'`
LegendI[vmstat2]: swapped
LegendO[vmstat2]: free
WithPeak[vmstat2]: ymwd
Options[vmstat2]: gauge,growright
#Factor[vmstat2]: 1024
#kMG[vmstat2]: ,n,u,m,,k,M,G,T
PageTop[vmstat2]: <h1>Speicher-Auslastung (swap/free)</h1>
Title[uptime0]: System-Auslastung (loadavg)
MaxBytes[uptime0]: 200
ShortLegend[uptime0]: load
YLegend[uptime0]: load
Legend1[uptime0]: load
Target[uptime0]: `uptime | awk '{printf("%fn%fn",$8,$10)}'`
LegendI[uptime0]: load 1m
LegendO[uptime0]: load 15m
Factor[uptime0]: 1
WithPeak[uptime0]: ymwd
Options[uptime0]: gauge,growright,withzeroes
PageTop[uptime0]: <h1>System-Auslastung (loadavg)</h1>
Habt Ihr ne Idee? Ich meine, 280 MB in gut einem Tag, Daten werden alle 5 Minuten ausgelesen, das heißt ca. 300 mal am Tag. Die ganzen Aufrufe geben eigentlich nur Zahlen aus, da kann eigentlich nicht so viel anfallen, eher bei snmp. MRTG bietet ja auch debug-Optionen, hat da jemand Erfahrungen mit, welche Informationen hier interessant sein können?
Aus man mrtg:
Code: Select all
--debug=s
Enable debug options. The argument of the debug option is a comma separated list of debug values:
cfg - watch the config file reading
dir - directory mangeling
base - basic program flow
tarp - target parser
snpo - snmp polling
fork - forking view
time - some timing info
log - logging of data via rateup or rrdtool
Example:
--debug="cfg,snpo"
Ich weiß allerdings nicht wie mir diese Infos weiterhelfen könnten, oder? Kann es was mit grsec zu tun haben?
Viele Grüße
Andreas