[mrtg] New Mrtg Server very high CPU usage.

Steve Shipway s.shipway at auckland.ac.nz
Tue Aug 12 05:35:29 CEST 2008


You might find it more efficient (on a UNIX server) to create a master.cfg file that uses Include: to include each of the other files, and Forks: to set a value depending on your servers power (try 20 for a start and see if it completes in time) and then run MRTG in daemon mode.  EG:

RunAsDaemon: yes
Forks: 20
Include: file1.cfg
Include: file2.cfg
routers.cgi*Ignore: yes

(the last line is for if you use the routers2 frontend).  Its a shame you can't (currently) use a wildcard in the Include: directive.

Once you have set this up, increase the Forks value if the polling cycle take >4mins, and decrease it if your CPU and memory use get too high.  If both are the case, then get a bigger server and/or faster disks :)

Steve



More information about the mrtg mailing list