[mrtg] New Mrtg Server very high CPU usage.

Nico Kadel-Garcia nkadel at gmail.com
Sat Aug 9 20:00:20 CEST 2008


DA Forsyth wrote:
> On 7 Aug 2008 , Mersberger, Robert entreated about
>  "[mrtg] New Mrtg Server very high CPU usage.":
>
>   
>> runs via a cron job every 5 minutes
>> #############
>> mrtg_run
>> ############
>> #! /bin/bash
>>
>> for fn in /etc/mrtg/*.cfg; do
>>         env LANG=C /usr/bin/mrtg "$fn" &
>> done
>> ####################################
>>
>> I am looking for ways to improve performance  have some cpu left over
>> for other task.
>>     
>
> only start every odd numbered script in the back ground to spread the 
> load a bit.  i do this in all my mrtg setups, for example
>
> --- script called by cron ---
> mrtg setup1.cfg &
> mrtg setup2.cfg
> mrtg setup3.cfg &
> mrtg setup4.cfg
>   
I tend to spread them around by splitting them up into five different 
files, started one minute apart, or even with a 'sleep 30' written into 
the cron job to get them *off* the 0-second mark.



More information about the mrtg mailing list