System Administration

SNMP setup for MRTG on Red Hat 7

Occasional Contributor

SNMP setup for MRTG on Red Hat 7

I would like to configure the MRTG for my Apache server. However, I don't know how to setup the SNMP. Anyone pls help. Thanks a lot.
Pal Szabo_1
Valued Contributor

Re: SNMP setup for MRTG on Red Hat 7


First of all, you should download
1. MRTG (
2. Apache (
3. Mod-SNMP for apache (SNMP module for apache)

And if you don't have, you should download perl, gd , gcc(for MRTG)

The apache compilation is straigtforward, and this page explains the SNMP module installation too.

The MRTG installation is explained on this page too.

If your apache is running you
can query directly the SNMP variables with snmpwalk software.This is the part of cmu-snmp software.
( or ucd-snmp-
You should try:
snmpwalk public

And you should see the apache
snmp variables, if it works correctly.

If you installed these softwares, you should set up MRTG config file (mrtg.cfg).
The easyest way is to use the
MRTG cfgmaker.This program generates the config file for you.

You should try:
--global "WorkDir: /home/paul" --global "Options[_]: growright,bits" public@myhostname > mrtg.cfg

I hope, my answare help you.