[mrtg] how to display two devices in one graph

Steve Shipway s.shipway at auckland.ac.nz
Wed May 14 00:56:59 CEST 2008

> I have mrtg running and have a config for our firewall and one for our
> vpn.
> How would I make it show the usage of the firewall and vpn in one
> using different colours.

I assume you mean to have 4 values being shown on the same graph.

To do this, you would need to be using RRDTool for your backend instead
of the native .log files.  Then you would need to use a frontend which
can handle combined graphs.  At the moment, that means write one
yourself or else use the routers2 frontend, in which you can define a
UserDefined summary graph over multiple targets.

> The other one im a bit confused with is I can have one config with a
> devices but I have to run cfgmaker for each device and add them to one
> cfg.
> Can you make cfgmaker produce one cfg with many devices?

Cfgmaker processes a single device.  It is generally considered best
practice to have one .cfg file per device being monitored; if for some
reason you need to have a single file (such as to run MRTG on it in one
pass) then you create a separate 'master.cfg' file which uses the
'Include:' directive to include all the various child cfg files.  

I am not exactly being impartial when suggesting to use routers2 as the
frontend, though :)

For a routers2 demo (including combined graphs) see


More information about the mrtg mailing list