Seems to be a regular request to change the reporting screens from "percent utilization" to an absolute rate; mbps or even just bits per second. The official way to do this (per Ipswitch) is to create new active monitors. But here's an easier way (note, this is a hack, not supported by Ipswitch).
The one down side is you have to pick a single rate in which to report all circuits, that is, the graph can be changed to report "bits per second", or "megabits per second", but there's no easy way to have it change intelligently based on the circuit. What that means is, your sub-rate T1 lines and 10-gigabit switchports must all be reported in the same rate.
The instructions below will change the graphs to "mbps" which should be good enough for most situtations.
Browse deep into the WUG installation directory to:
[sourcecode language="php" gutter="false"]c:\Program Files\Ipswitch\WhatsUp\HTML\NmConsole\Reports\Full\Device\Performance\RptInterfaceUtilization[/sourcecode]
Make of copy of the file "_RptInterfaceUtilization.inc" and save this original file--just in case.
Open up _RptInterfaceUtilization in your favorite text editor.
Look in the top section, around line 10 for the line:
[sourcecode language="php" gutter="false"]oAspForm.DeclareTranslation("sPercentUtilization", "Percent Utilization");[/sourcecode]
This is what gets printed on the vertical axis. Change the second parameter to read:
[sourcecode language="php" gutter="false"]oAspForm.DeclareTranslation("sPercentUtilization", "Mbits per second");[/sourcecode]
This is just a text field so it be whatever you want. Just keep it realitively short.
Now, scroll down to somewhere around line 35 for this section:
[sourcecode language="php" gutter="false"]" ((nIfInOctets_Avg * 8.0) / (1.0 * NULLIF(nIfSpeedIn, 0))) * 100.0 AS nIfInOctetsUtilization, " +
" ((nIfOutOctets_Avg * 8.0) / (1.0 * NULLIF(nIfSpeedOut, 0))) * 100.0 AS nIfOutOctetsUtilization, " +
" ((nIfInOctets_Max * 8.0) / (1.0 * NULLIF(nIfSpeedIn, 0))) * 100.0 AS nIfInOctetsUtilizationMax, " +
" ((nIfOutOctets_Max * 8.0) / (1.0 * NULLIF(nIfSpeedOut, 0))) * 100.0 AS nIfOutOctetsUtilizationMax " +[/sourcecode]
These lines take the sampled interface rate and divide it by the maximum interface speed to get the percentage. We need to alter this formula to just give us the absolute rate in Mbps. Since SNMP reports octets we still need to multiple by 8 to get bits and then divide by 1 million to get megabits. Change these lines to:
[sourcecode language="php" gutter="false"]" ((nIfInOctets_Avg * 8.0)/1000000) AS nIfInOctetsUtilization, " +
" ((nIfOutOctets_Avg * 8.0)/1000000) AS nIfOutOctetsUtilization, " +
" ((nIfInOctets_Max * 8.0)/1000000) AS nIfInOctetsUtilizationMax, " +
" ((nIfOutOctets_Max * 8.0)/1000000) AS nIfOutOctetsUtilizationMax " +[/sourcecode]
Be careful that the parens match, as to do the quotes. Double check your work and save this file. Make sure it gets saved with the exact same file name and it only has an extension of ".inc"
Fire up your interface utilization reports and send them to the management team.
I should add that an WUG upgrade might possibly overwrite these changes.
Thursday, December 17, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment