Pejman Moghadam / General

Using MRTG for CPU, memory and hard disk usage of Linux

Public domain


mrtg.cfg for Linux CPU usage

LoadMIBs: /usr/share/snmp/mibs/UCD-SNMP-MIB.txt
workdir: /var/www/html/mrtg

Target[linux_server_cpu_load]: ( ssCpuRawUser.0&ssCpuRawUser.0:public@192.168.1.2 ) + ( ssCpuRawSystem.0&ssCpuRawSystem.0:public@192.168.1.2 ) + ( ssCpuRawNice.0&ssCpuRawNice.0:public@192.168.1.2 )

Title[linux_server_cpu_load]: CPU Utilization for Linux Server
PageTop[linux_server_cpu_load]: <H1> CPU Utilization for Linux Server </H1>
MaxBytes[linux_server_cpu_load]: 100
ShortLegend[linux_server_cpu_load]: %
YLegend[linux_server_cpu_load]: % of CPU Load
Legend1[linux_server_cpu_load]: CPU Utilization
LegendI[linux_server_cpu_load]: CPU Load :
LegendO[linux_server_cpu_load]:
Options[linux_server_cpu_load]: nopercent
Unscaled[linux_server_cpu_load]: ymwd

mrtg.cfg for Linux memory usage

LoadMIBs: /usr/share/snmp/mibs/HOST-RESOURCES-MIB.txt
workdir: /var/www/html/mrtg

Target[linux_server_mem_ram]: ( hrStorageUsed.101&hrStorageUsed.101:public@192.168.1.2 ) * 100 / ( hrStorageSize.101&hrStorageSize.101:public@192.168.1.2 )

Title[linux_server_mem_ram]: Memory usage for Linux Server
PageTop[linux_server_mem_ram]: <H1> Memory usage for Linux Server </H1>
MaxBytes[linux_server_mem_ram]: 100
ShortLegend[linux_server_mem_ram]: %
YLegend[linux_server_mem_ram]: % of Memory
Legend1[linux_server_mem_ram]: Used Memory
LegendI[linux_server_mem_ram]: Used :
LegendO[linux_server_mem_ram]:
Options[linux_server_mem_ram]: nopercent, gauge, integer
Unscaled[linux_server_mem_ram]: ymwd

Target[linux_server_mem_swap]: ( hrStorageUsed.102&hrStorageUsed.102:public@192.168.1.2 ) * 100 / ( hrStorageSize.102&hrStorageSize.102:public@192.168.1.2 )

Title[linux_server_mem_swap]: Swap usage for Linux Server
PageTop[linux_server_mem_swap]: <H1> Swap usage for Linux Server </H1>
MaxBytes[linux_server_mem_swap]: 100
ShortLegend[linux_server_mem_swap]: %
YLegend[linux_server_mem_swap]: % of Swap
Legend1[linux_server_mem_swap]: Used Swap
LegendI[linux_server_mem_swap]: Used :
LegendO[linux_server_mem_swap]:
Options[linux_server_mem_swap]: nopercent, gauge, integer
Unscaled[linux_server_mem_swap]: ymwd

mrtg.cfg for Linux Partition usage

LoadMIBs: /usr/share/snmp/mibs/HOST-RESOURCES-MIB.txt
workdir: /var/www/html/mrtg

Target[linux_server_dsk]: ( hrStorageUsed.1&hrStorageUsed.1:public@192.168.1.2 ) * 100 / ( hrStorageSize.1&hrStorageSize.1:public@192.168.1.2 )

Title[linux_server_dsk]: [/] Partition usage for Linux Server
PageTop[linux_server_dsk]: <H1> [/] Partition usage for Linux Server </H1>
MaxBytes[linux_server_dsk]: 100
ShortLegend[linux_server_dsk]: %
YLegend[linux_server_dsk]: % of Space
Legend1[linux_server_dsk]: Used Space
LegendI[linux_server_dsk]: Used :
LegendO[linux_server_dsk]:
Options[linux_server_dsk]: nopercent, gauge, integer
Unscaled[linux_server_dsk]: ymwd

BY: Pejman Moghadam
TAG: mrtg
DATE: 2009-04-25 00:15:07


Pejman Moghadam / General [ TXT ]