Fixed Cisco MAC accounting discovery, polling and HTML templates. (#10158)

* Fix Cisco MAC acounting discovery, polling and HTML templates.

* Remove empty code.

* Provide test data for cisco-mac-accounting module.

* Added module test dependency.
This commit is contained in:
Jozef Pivarník
2019-05-21 03:56:19 +02:00
committed by Tony Murray
parent 4387ab052e
commit 2dc05ee501
10 changed files with 39031 additions and 30 deletions

View File

@@ -28,7 +28,7 @@ if ($stat == 'pkts') {
} elseif ($sort == 'out') {
$sort = 'cipMacHCSwitchedPkts_output_rate';
} else {
$sort = 'bps';
$sort = 'bps_in';
}
} elseif ($stat == 'bits') {
$units = 'bps';
@@ -40,7 +40,7 @@ if ($stat == 'pkts') {
} elseif ($sort == 'out') {
$sort = 'cipMacHCSwitchedBytes_output_rate';
} else {
$sort = 'bps';
$sort = 'bps_in';
}
}//end if
@@ -107,10 +107,10 @@ foreach ($accs as $acc) {
$rrd_options .= ' VDEF:tot'.$this_id.'=octets'.$this_id.',TOTAL';
$rrd_options .= ' AREA:inB'.$this_id.'#'.$colour.":'".$descr."':STACK";
if ($rrd_optionsb) {
$stack = 'STACK';
$stack = ':STACK';
}
$rrd_optionsb .= ' AREA:outB'.$this_id.'#'.$colour."::$stack";
$rrd_optionsb .= ' AREA:outB'.$this_id.'#'.$colour.":''$stack";
$rrd_options .= ' GPRINT:inB'.$this_id.":LAST:%6.2lf%s$units";
$rrd_options .= ' GPRINT:inB'.$this_id.":MAX:%6.2lf%s$units";
$rrd_options .= ' GPRINT:totin'.$this_id.":%6.2lf%s$unit";