rra? no. you mean ds. also make multi_bits_separated prettier

git-svn-id: http://www.observium.org/svn/observer/trunk@2534 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Adam Amstrong
2011-09-21 11:59:59 +00:00
parent 86c6a817ad
commit a9cac94659
69 changed files with 231 additions and 210 deletions

View File

@ -11,7 +11,7 @@ if (is_file($apache_rrd))
$rrd_filename = $apache_rrd;
}
$rra = "kbyte";
$ds = "kbyte";
$colour_area = "CDEB8B";
$colour_line = "006600";

View File

@ -11,7 +11,7 @@ if (is_file($apache_rrd))
$rrd_filename = $apache_rrd;
}
$rra = "cpu";
$ds = "cpu";
$colour_area = "AA66AA";
$colour_line = "FFDD88";

View File

@ -11,7 +11,7 @@ if (is_file($apache_rrd))
$rrd_filename = $apache_rrd;
}
$rra = "access";
$ds = "access";
$colour_area = "AA66AA";
$colour_line = "FFDD88";

View File

@ -27,7 +27,7 @@ if (is_file($rrd_filename))
{
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $vars['descr'];
$rrd_list[$i]['rra'] = $ds;
$rrd_list[$i]['ds'] = $ds;
$rrd_list[$i]['colour'] = $vars['colour'];
$i++;
}

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "inpacketoctets";
$rra_out = "outpacketoctets";
$ds_in = "inpacketoctets";
$ds_out = "outpacketoctets";
include("includes/graphs/generic_bits.inc.php");

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "incells";
$rra_out = "outcells";
$ds_in = "incells";
$ds_out = "outcells";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "inpacketerrors";
$rra_out = "outpacketerrors";
$ds_in = "inpacketerrors";
$ds_out = "outpacketerrors";
$colour_area_in = "FF3300";
$colour_line_in = "FF0000";

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "inpackets";
$rra_out = "outpackets";
$ds_in = "inpackets";
$ds_out = "outpackets";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -4,7 +4,7 @@ include("includes/graphs/common.inc.php");
$scale_min = "0";
$rra = "AcceptedPrefixes";
$ds = "AcceptedPrefixes";
$colour_area = "AA66AA";
$colour_line = "FFDD88";

View File

@ -4,8 +4,8 @@ $scale_min = "0";
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename("bgp-" . $data['bgpPeerIdentifier'] . ".rrd");
$rra_in = "bgpPeerInUpdates";
$rra_out = "bgpPeerOutUpdates";
$ds_in = "bgpPeerInUpdates";
$ds_out = "bgpPeerOutUpdates";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -21,8 +21,8 @@ $multiplier = "8";
$colours_out = 'blues';
$nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
#print_r($rates);

View File

@ -10,10 +10,10 @@ if (is_file($rrd_filename))
foreach ($oids as $oid)
{
$oid = str_replace("dot3Stats", "", $oid);
$oid_rra = truncate($oid, 19, '');
$oid_ds = truncate($oid, 19, '');
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $oid;
$rrd_list[$i]['rra'] = $oid_rra;
$rrd_list[$i]['ds'] = $oid_ds;
$i++;
}
}

View File

@ -23,8 +23,8 @@ $colours_out = 'blues';
$nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
include("includes/graphs/generic_multi_bits_separated.inc.php");

View File

@ -34,15 +34,15 @@ foreach (dbFetchRows("SELECT * FROM `ports` WHERE `device_id` = ?", array($id))
$rrd_filenames[] = $rrd_filename;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $port['ifDescr'];
$rrd_list[$i]['rra_in'] = $rra_in;
$rrd_list[$i]['rra_out'] = $rra_out;
$rrd_list[$i]['ds_in'] = $ds_in;
$rrd_list[$i]['ds_out'] = $ds_out;
$i++;
}
unset($ignore);
}
$units ='bps';
$units ='b';
$total_units ='B';
$colours_in ='greens';
$multiplier = "8";
@ -51,8 +51,8 @@ $colours_out = 'blues';
$nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
$graph_title .= "::bits";

View File

@ -2,8 +2,8 @@
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/cipsec_flow.rrd";
$rra_in = "InOctets";
$rra_out = "OutOctets";
$ds_in = "InOctets";
$ds_out = "OutOctets";
include("includes/graphs/generic_bits.inc.php");

View File

@ -2,8 +2,8 @@
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/cipsec_flow.rrd";
$rra_in = "InPkts";
$rra_out = "OutPkts";
$ds_in = "InPkts";
$ds_out = "OutPkts";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -7,69 +7,69 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/cipsec_flow.r
$i=0;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InAuths";
$rrd_list[$i]['rra'] = "InAuths";
$rrd_list[$i]['ds'] = "InAuths";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "OutAuths";
$rrd_list[$i]['rra'] = "OutAuths";
$rra_list[$i]['invert'] = "1";
$rrd_list[$i]['ds'] = "OutAuths";
$ds_list[$i]['invert'] = "1";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InDecrypts";
$rrd_list[$i]['rra'] = "InDencrypts";
$rrd_list[$i]['ds'] = "InDencrypts";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "OutEncrypts";
$rrd_list[$i]['rra'] = "OutEncrypts";
$rra_list[$i]['invert'] = "1";
$rrd_list[$i]['ds'] = "OutEncrypts";
$ds_list[$i]['invert'] = "1";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InDrops";
$rrd_list[$i]['rra'] = "InDrops";
$rrd_list[$i]['ds'] = "InDrops";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InReplayDrops";
$rrd_list[$i]['rra'] = "InReplayDrops";
$rrd_list[$i]['ds'] = "InReplayDrops";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "OutDrops";
$rrd_list[$i]['rra'] = "OutDrops";
$rra_list[$i]['invert'] = "1";
$rrd_list[$i]['ds'] = "OutDrops";
$ds_list[$i]['invert'] = "1";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InAuthFail";
$rrd_list[$i]['rra'] = "InAuthFails";
$rrd_list[$i]['ds'] = "InAuthFails";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "OutAuthFail";
$rrd_list[$i]['rra'] = "OutAuthFails";
$rra_list[$i]['invert'] = "1";
$rrd_list[$i]['ds'] = "OutAuthFails";
$ds_list[$i]['invert'] = "1";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "InDecryptFails";
$rrd_list[$i]['rra'] = "InDecryptFails";
$rrd_list[$i]['ds'] = "InDecryptFails";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "OutEncryptFails";
$rrd_list[$i]['rra'] = "OutEncryptFails";
$rra_list[$i]['invert'] = "1";
$rrd_list[$i]['ds'] = "OutEncryptFails";
$ds_list[$i]['invert'] = "1";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "ProtocolUseFails";
$rrd_list[$i]['rra'] = "ProtocolUseFails";
$rrd_list[$i]['ds'] = "ProtocolUseFails";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "NoSaFails";
$rrd_list[$i]['rra'] = "NoSaFails";
$rrd_list[$i]['ds'] = "NoSaFails";
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = "SysCapFails";
$rrd_list[$i]['rra'] = "SysCapFails";
$rrd_list[$i]['ds'] = "SysCapFails";
#$units='%';
#$total_units='%';

View File

@ -4,7 +4,7 @@ include("includes/graphs/common.inc.php");
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/cipsec_flow.rrd";
$rra = "Tunnels";
$ds = "Tunnels";
$colour_area = "9999cc";
$colour_line = "0000cc";

View File

@ -7,7 +7,7 @@
* Foundation; only version 2 of the License is applicable.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* ANY WARRANTY; without even the implied wadsnty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
* details.
*

View File

@ -7,8 +7,8 @@ $multiplier = "8";
$colours_out = 'blues';
$nototal = 1;
$rra_in = "read";
$rra_out = "written";
$ds_in = "read";
$ds_out = "written";
include("includes/graphs/device/diskio_common.inc.php");

View File

@ -9,8 +9,8 @@ foreach (dbFetchRows("SELECT * FROM `ucd_diskio` AS U, `devices` AS D WHERE D.de
{
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $disk['diskio_descr'];
$rrd_list[$i]['rra_in'] = $rra_in;
$rrd_list[$i]['rra_out'] = $rra_out;
$rrd_list[$i]['ds_in'] = $ds_in;
$rrd_list[$i]['ds_out'] = $ds_out;
$i++;
}
}

View File

@ -7,8 +7,8 @@ $colours_in = 'greens';
$multiplier = "1";
$colours_out = 'blues';
$rra_in = "reads";
$rra_out = "writes";
$ds_in = "reads";
$ds_out = "writes";
$nototal = 1;

View File

@ -22,7 +22,7 @@ foreach($stats as $stat => $colour)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("icmp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -22,7 +22,7 @@ foreach($stats as $stat => $array)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("icmp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -19,7 +19,7 @@ foreach($stats as $stat => $array)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("ip", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -19,7 +19,7 @@ foreach($stats as $stat)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("snmp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -14,7 +14,7 @@ foreach($stats as $stat)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("snmp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -13,7 +13,7 @@ foreach($stats as $stat)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("tcp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE || strpos($stat, "Retrans") !== FALSE || strpos($stat, "Attempt") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -13,7 +13,7 @@ foreach($stats as $stat)
$i++;
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = str_replace("udp", "", $stat);
$rrd_list[$i]['rra'] = $stat;
$rrd_list[$i]['ds'] = $stat;
if (strpos($stat, "Out") !== FALSE || strpos($stat, "Retrans") !== FALSE || strpos($stat, "Attempt") !== FALSE)
{
$rrd_list[$i]['invert'] = TRUE;

View File

@ -27,15 +27,15 @@ foreach ( $config['nfsen_rrds'] as $nfsenrrds )
$rrd_list[$nfsen_iter]['filename'] = $rrd_filename;
$rrd_list[$nfsen_iter]['descr'] = $flowtype;
$rrd_list[$nfsen_iter]['rra'] = $rraprefix . $flowtype;
$rrd_list[$nfsen_iter]['ds'] = $dsprefix . $flowtype;
# set a multiplier which in turn will create a CDEF if this var is set
if ($rraprefix == "traffic_") { $multiplier = "8"; }
if ($dsprefix == "traffic_") { $multiplier = "8"; }
$colours = "blues";
$nototal = 0;
$units="";
$unit_text = $rradescr;
$unit_text = $dsdescr;
$scale_min = "0";
if ($_GET['debug']) { print_r($rrd_list); }

View File

@ -1,5 +1,5 @@
<?php
$rradescr = "Flows/s ";
$rraprefix = "flows_";
$dsdescr = "Flows/s ";
$dsprefix = "flows_";
include("nfsen_common.inc.php");
?>

View File

@ -1,5 +1,5 @@
<?php
$rradescr = "Packets/s ";
$rraprefix = "packets_";
$dsdescr = "Packets/s ";
$dsprefix = "packets_";
include("nfsen_common.inc.php");
?>

View File

@ -1,5 +1,5 @@
<?php
$rradescr = "Byts/s ";
$rraprefix = "traffic_";
$dsdescr = "Byts/s ";
$dsprefix = "traffic_";
include("nfsen_common.inc.php");
?>

View File

@ -12,7 +12,7 @@ foreach ($procs as $proc)
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $descr;
$rrd_list[$i]['rra'] = "usage";
$rrd_list[$i]['ds'] = "usage";
$rrd_list[$i]['area'] = 1;
$i++;
}

View File

@ -12,7 +12,7 @@ foreach ($procs as $proc)
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $descr;
$rrd_list[$i]['rra'] = "usage";
$rrd_list[$i]['ds'] = "usage";
$i++;
}
}

View File

@ -8,15 +8,15 @@ $file = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename("screeno
$rrd_list[0]['filename'] = $file;
$rrd_list[0]['descr'] = "Maxiumum";
$rrd_list[0]['rra'] = "max";
$rrd_list[0]['ds'] = "max";
$rrd_list[1]['filename'] = $file;
$rrd_list[1]['descr'] = "Allocated";
$rrd_list[1]['rra'] = "allocate";
$rrd_list[1]['ds'] = "allocate";
$rrd_list[2]['filename'] = $file;
$rrd_list[2]['descr'] = "Failed";
$rrd_list[2]['rra'] = "failed";
$rrd_list[2]['ds'] = "failed";
if ($_GET['debug']) { print_r($rrd_list); }

View File

@ -4,7 +4,7 @@ include("includes/graphs/common.inc.php");
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssRawContexts.rrd";
$rra = "value";
$ds = "value";
$colour_area = "9999cc";
$colour_line = "0000cc";

View File

@ -4,7 +4,7 @@ include("includes/graphs/common.inc.php");
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssRawInterrupts.rrd";
$rra = "value";
$ds = "value";
$colour_area = "CC9999";
$colour_line = "CC0000";

View File

@ -2,8 +2,8 @@
$rrd_filename_in = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssIORawReceived.rrd";
$rrd_filename_out = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssIORawSent.rrd";
$rra_in = "value";
$rra_out = "value";
$ds_in = "value";
$ds_out = "value";
$multiplier = 512;

View File

@ -2,8 +2,8 @@
$rrd_filename_in = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssRawSwapIn.rrd";
$rrd_filename_out = $config['rrd_dir'] . "/" . $device['hostname'] . "/ucd_ssRawSwapOut.rrd";
$rra_in = "value";
$rra_out = "value";
$ds_in = "value";
$ds_out = "value";
$multiplier = 512;

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "read";
$rra_out = "written";
$ds_in = "read";
$ds_out = "written";
include("includes/graphs/generic_bytes.inc.php");

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "reads";
$rra_out = "writes";
$ds_in = "reads";
$ds_out = "writes";
$colour_area_in = "FF3300";
$colour_line_in = "FF0000";

View File

@ -1,7 +1,7 @@
<?php
/// Draw generic bits graph
/// args: rra_in, rra_out, rrd_filename, bg, legend, from, to, width, height, inverse
/// args: ds_in, ds_out, rrd_filename, bg, legend, from, to, width, height, inverse
include("includes/graphs/common.inc.php");
@ -11,19 +11,19 @@ if ($inverse) { $in = 'out'; $out = 'in'; } else { $in = 'in'; $out = 'out'; }
if ($multiplier)
{
$rrd_options .= " DEF:p".$out."octets=".$rrd_filename_out.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:p".$in."octets=".$rrd_filename_in.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:p".$out."octets_max=".$rrd_filename_out.":".$rra_out.":MAX";
$rrd_options .= " DEF:p".$in."octets_max=".$rrd_filename_in.":".$rra_in.":MAX";
$rrd_options .= " DEF:p".$out."octets=".$rrd_filename_out.":".$ds_out.":AVERAGE";
$rrd_options .= " DEF:p".$in."octets=".$rrd_filename_in.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:p".$out."octets_max=".$rrd_filename_out.":".$ds_out.":MAX";
$rrd_options .= " DEF:p".$in."octets_max=".$rrd_filename_in.":".$ds_in.":MAX";
$rrd_options .= " CDEF:inoctets=pinoctets,$multiplier,*";
$rrd_options .= " CDEF:outoctets=poutoctets,$multiplier,*";
$rrd_options .= " CDEF:inoctets_max=pinoctets_max,$multiplier,*";
$rrd_options .= " CDEF:outoctets_max=poutoctets_max,$multiplier,*";
} else {
$rrd_options .= " DEF:".$out."octets=".$rrd_filename_out.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:".$in."octets=".$rrd_filename_in.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets_max=".$rrd_filename_out.":".$rra_out.":MAX";
$rrd_options .= " DEF:".$in."octets_max=".$rrd_filename_in.":".$rra_in.":MAX";
$rrd_options .= " DEF:".$out."octets=".$rrd_filename_out.":".$ds_out.":AVERAGE";
$rrd_options .= " DEF:".$in."octets=".$rrd_filename_in.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets_max=".$rrd_filename_out.":".$ds_out.":MAX";
$rrd_options .= " DEF:".$in."octets_max=".$rrd_filename_in.":".$ds_in.":MAX";
}
$rrd_options .= " CDEF:octets=inoctets,outoctets,+";

View File

@ -1,7 +1,7 @@
<?php
/// Draw generic octets graph
/// args: rra_in, rra_out, rrd_filename, bg, legend, from, to, width, height, inverse
/// args: ds_in, ds_out, rrd_filename, bg, legend, from, to, width, height, inverse
include("includes/graphs/common.inc.php");
@ -12,19 +12,19 @@ if ($inverse) { $in = 'out'; $out = 'in'; } else { $in = 'in'; $out = 'out'; }
if ($multiplier)
{
$rrd_options .= " DEF:p".$out."octets=".$rrd_filename_out.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:p".$in."octets=".$rrd_filename_in.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:p".$out."octets_max=".$rrd_filename_out.":".$rra_out.":MAX";
$rrd_options .= " DEF:p".$in."octets_max=".$rrd_filename_in.":".$rra_in.":MAX";
$rrd_options .= " DEF:p".$out."octets=".$rrd_filename_out.":".$ds_out.":AVERAGE";
$rrd_options .= " DEF:p".$in."octets=".$rrd_filename_in.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:p".$out."octets_max=".$rrd_filename_out.":".$ds_out.":MAX";
$rrd_options .= " DEF:p".$in."octets_max=".$rrd_filename_in.":".$ds_in.":MAX";
$rrd_options .= " CDEF:inoctets=pinoctets,$multiplier,*";
$rrd_options .= " CDEF:outoctets=poutoctets,$multiplier,*";
$rrd_options .= " CDEF:inoctets_max=pinoctets_max,$multiplier,*";
$rrd_options .= " CDEF:outoctets_max=poutoctets_max,$multiplier,*";
} else {
$rrd_options .= " DEF:".$out."octets=".$rrd_filename_out.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:".$in."octets=".$rrd_filename_in.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets_max=".$rrd_filename_out.":".$rra_out.":MAX";
$rrd_options .= " DEF:".$in."octets_max=".$rrd_filename_in.":".$rra_in.":MAX";
$rrd_options .= " DEF:".$out."octets=".$rrd_filename_out.":".$ds_out.":AVERAGE";
$rrd_options .= " DEF:".$in."octets=".$rrd_filename_in.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets_max=".$rrd_filename_out.":".$ds_out.":MAX";
$rrd_options .= " DEF:".$in."octets_max=".$rrd_filename_in.":".$ds_in.":MAX";
}
$rrd_options .= " CDEF:octets=inoctets,outoctets,+";

View File

@ -1,7 +1,7 @@
<?php
/// Draw generic bits graph
/// args: rra_in, rra_out, rrd_filename, bg, legend, from, to, width, height, inverse, $percentile
/// args: ds_in, ds_out, rrd_filename, bg, legend, from, to, width, height, inverse, $percentile
include("includes/graphs/common.inc.php");
@ -16,10 +16,10 @@ $unit_text = str_pad(truncate($unit_text,$length),$length);
$in_text = str_pad(truncate($in_text,$length),$length);
$out_text = str_pad(truncate($out_text,$length),$length);
$rrd_options .= " DEF:".$out."=".$rrd_filename.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:".$in."=".$rrd_filename.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:".$out."_max=".$rrd_filename.":".$rra_out.":MAX";
$rrd_options .= " DEF:".$in."_max=".$rrd_filename.":".$rra_in.":MAX";
$rrd_options .= " DEF:".$out."=".$rrd_filename.":".$ds_out.":AVERAGE";
$rrd_options .= " DEF:".$in."=".$rrd_filename.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:".$out."_max=".$rrd_filename.":".$ds_out.":MAX";
$rrd_options .= " DEF:".$in."_max=".$rrd_filename.":".$ds_in.":MAX";
$rrd_options .= " CDEF:dout_max=out_max,-1,*";
$rrd_options .= " CDEF:dout=out,-1,*";

View File

@ -11,8 +11,8 @@ foreach ($rrd_filenames as $key => $rrd_filename)
{
if ($rrd_inverted[$key]) { $in = 'out'; $out = 'in'; } else { $in = 'in'; $out = 'out'; }
$rrd_options .= " DEF:".$in."octets" . $i . "=".$rrd_filename.":".$rra_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets" . $i . "=".$rrd_filename.":".$rra_out.":AVERAGE";
$rrd_options .= " DEF:".$in."octets" . $i . "=".$rrd_filename.":".$ds_in.":AVERAGE";
$rrd_options .= " DEF:".$out."octets" . $i . "=".$rrd_filename.":".$ds_out.":AVERAGE";
$in_thing .= $seperator . "inoctets" . $i . ",UN,0," . "inoctets" . $i . ",IF";
$out_thing .= $seperator . "outoctets" . $i . ",UN,0," . "outoctets" . $i . ",IF";
$pluses .= $plus;

View File

@ -3,12 +3,29 @@
include("includes/graphs/common.inc.php");
$i = 0;
if($width > "500")
{
$descr_len=18;
} else {
$descr_len=8;
$descr_len += round(($width - 250) / 8);
}
$unit_text = "Bits/sec";
$rrd_options .= " COMMENT:'".substr(str_pad($unit_text, $descr_len+5),0,$descr_len+5)."'";
if($width > "500")
{
$rrd_options .= " COMMENT:'In\: Current Maximum '";
if (!$nototal) { $rrd_options .= " COMMENT:'Total '"; }
$rrd_options .= " COMMENT:'Out\: Current Maximum'";
if (!$nototal) { $rrd_options .= " COMMENT:' Total'"; }
$rrd_options .= " COMMENT:'\l'";
} else {
$rrd_options .= " COMMENT:' Now Ave Max\l'";
}
$rrd_options .= " COMMENT:' In\: Current Maximum '";
if (!$nototal) { $rrd_options .= " COMMENT:'Total '"; }
$rrd_options .= " COMMENT:'Out\: Current Maximum'";
if (!$nototal) { $rrd_options .= " COMMENT:' Total'"; }
$rrd_options .= " COMMENT:'\\n'";
if(!isset($multiplier)) { $multiplier = "8"; }
foreach ($rrd_list as $rrd)
@ -18,10 +35,15 @@ foreach ($rrd_list as $rrd)
$colour_in=$config['graph_colours'][$colours_in][$iter];
$colour_out=$config['graph_colours'][$colours_out][$iter];
$descr = str_replace(":", "\:", substr(str_pad($rrd['descr'], 18),0,18));
$descr = str_replace(":", "\:", substr(str_pad($rrd['descr'], $descr_len),0,$descr_len)) . " In";
if(isset($rrd['descr_in']))
{
$descr = str_replace(":", "\:", substr(str_pad($rrd['descr_in'], $descr_len),0,$descr_len)) . " In";
}
$descr_out = str_replace(":", "\:", substr(str_pad($rrd['descr_out'], $descr_len),0,$descr_len)). " Out";
$rrd_options .= " DEF:".$in.$i."=".$rrd['filename'].":".$rra_in.":AVERAGE ";
$rrd_options .= " DEF:".$out.$i."=".$rrd['filename'].":".$rra_out.":AVERAGE ";
$rrd_options .= " DEF:".$in.$i."=".$rrd['filename'].":".$ds_in.":AVERAGE ";
$rrd_options .= " DEF:".$out.$i."=".$rrd['filename'].":".$ds_out.":AVERAGE ";
$rrd_options .= " CDEF:inB".$i."=in".$i.",$multiplier,* ";
$rrd_options .= " CDEF:outB".$i."=out".$i.",$multiplier,*";
$rrd_options .= " CDEF:outB".$i."_neg=outB".$i.",-1,*";
@ -34,24 +56,23 @@ foreach ($rrd_list as $rrd)
$rrd_options .= " VDEF:tot".$i."=octets".$i.",TOTAL";
}
$rrd_options .= " HRULE:999999999999999#" . $colour_out . ":\\\s:";
if ($i) { $stack="STACK"; }
$rrd_options .= " AREA:inB".$i."#" . $colour_in . ":'" . $descr . "':$stack";
$rrd_optionsb .= " AREA:outB".$i."_neg#" . $colour_out . "::$stack";
$rrd_options .= " GPRINT:inB".$i.":LAST:%6.2lf%s$units";
$rrd_options .= " GPRINT:inB".$i.":MAX:%6.2lf%s$units";
$rrd_options .= " GPRINT:inB".$i.":AVERAGE:%6.2lf%s$units";
$rrd_options .= " GPRINT:inB".$i.":MAX:%6.2lf%s$units\l";
if (!$nototal) { $rrd_options .= " GPRINT:totin".$i.":%6.2lf%s$total_units"; }
$rrd_options .= " COMMENT:' '";
$rrd_options .= " 'AREA:outB".$i."_neg#" . $colour_out . ":".$descr_out.":$stack'";
$rrd_options .= " GPRINT:outB".$i.":LAST:%6.2lf%s$units";
$rrd_options .= " GPRINT:outB".$i.":MAX:%6.2lf%s$units";
$rrd_options .= " GPRINT:outB".$i.":AVERAGE:%6.2lf%s$units";
$rrd_options .= " GPRINT:outB".$i.":MAX:%6.2lf%s$units\l";
if (!$nototal) { $rrd_options .= " GPRINT:totout".$i.":%6.2lf%s$total_unit"; }
$rrd_options .= " COMMENT:\\\\n";
$rrd_options .= " 'COMMENT:\l'";
$i++; $iter++;
}

View File

@ -17,7 +17,7 @@ foreach ($rrd_list as $rrd)
$colour=$config['graph_colours'][$colours][$iter];
$rra = $rrd['rra'];
$ds = $rrd['ds'];
$filename = $rrd['filename'];
$descr = $rrd['descr'];
$descr = substr(str_pad($descr, 10),0,10);
@ -25,12 +25,12 @@ foreach ($rrd_list as $rrd)
$id = "ds".$i;
$rrd_options .= " DEF:".$id."=$filename:$rra:AVERAGE";
$rrd_options .= " DEF:".$id."=$filename:$ds:AVERAGE";
if (!$basicrrd)
{
$rrd_options .= " DEF:".$id."min=$filename:$rra:MIN";
$rrd_options .= " DEF:".$id."max=$filename:$rra:MAX";
$rrd_options .= " DEF:".$id."min=$filename:$ds:MIN";
$rrd_options .= " DEF:".$id."max=$filename:$ds:MAX";
}
if ($rrd['invert'])

View File

@ -19,8 +19,8 @@ foreach ($rrd_list as $rrd)
if ($rrd['colour_area_in']) { $colour_in = $rrd['colour_area_in']; }
if ($rrd['colour_area_out']) { $colour_out = $rrd['colour_area_out']; }
$rrd_options .= " DEF:in".$i."=".$rrd['filename'].":".$rrd['rra_in'].":AVERAGE ";
$rrd_options .= " DEF:out".$i."=".$rrd['filename'].":".$rrd['rra_out'].":AVERAGE ";
$rrd_options .= " DEF:in".$i."=".$rrd['filename'].":".$rrd['ds_in'].":AVERAGE ";
$rrd_options .= " DEF:out".$i."=".$rrd['filename'].":".$rrd['ds_out'].":AVERAGE ";
$rrd_options .= " CDEF:inB".$i."=in".$i.",$multiplier,* ";
$rrd_options .= " CDEF:outB".$i."=out".$i.",$multiplier,*";
$rrd_options .= " CDEF:outB".$i."_neg=outB".$i.",-1,*";

View File

@ -23,39 +23,39 @@ foreach ($rrd_list as $i => $rrd)
$colour_iter++;
}
$rrd_options .= " DEF:".$rrd['rra'].$i."=".$rrd['filename'].":".$rrd['rra'].":AVERAGE ";
$rrd_options .= " DEF:".$rrd['rra'].$i."min=".$rrd['filename'].":".$rrd['rra'].":MIN ";
$rrd_options .= " DEF:".$rrd['rra'].$i."max=".$rrd['filename'].":".$rrd['rra'].":MAX ";
$rrd_options .= " DEF:".$rrd['ds'].$i."=".$rrd['filename'].":".$rrd['ds'].":AVERAGE ";
$rrd_options .= " DEF:".$rrd['ds'].$i."min=".$rrd['filename'].":".$rrd['ds'].":MIN ";
$rrd_options .= " DEF:".$rrd['ds'].$i."max=".$rrd['filename'].":".$rrd['ds'].":MAX ";
## Suppress totalling?
if (!$nototal)
{
$rrd_options .= " VDEF:tot".$rrd['rra'].$i."=".$rrd['rra'].$i.",TOTAL";
$rrd_options .= " VDEF:tot".$rrd['ds'].$i."=".$rrd['ds'].$i.",TOTAL";
}
## This this not the first entry?
if ($i) { $stack="STACK"; }
# if we've been passed a multiplier we must make a CDEF based on it!
$g_defname = $rrd['rra'];
$g_defname = $rrd['ds'];
if (is_numeric($multiplier))
{
$g_defname = $rrd['rra'] . "_cdef";
$rrd_options .= " CDEF:" . $g_defname . $i . "=" . $rrd['rra'] . $i . "," . $multiplier . ",*";
$rrd_options .= " CDEF:" . $g_defname . $i . "max=" . $rrd['rra'] . $i . "max," . $multiplier . ",*";
$g_defname = $rrd['ds'] . "_cdef";
$rrd_options .= " CDEF:" . $g_defname . $i . "=" . $rrd['ds'] . $i . "," . $multiplier . ",*";
$rrd_options .= " CDEF:" . $g_defname . $i . "max=" . $rrd['ds'] . $i . "max," . $multiplier . ",*";
## If we've been passed a divider (divisor!) we make a CDEF for it.
} elseif (is_numeric($divider))
{
$g_defname = $rrd['rra'] . "_cdef";
$rrd_options .= " CDEF:" . $g_defname . $i . "=" . $rrd['rra'] . $i . "," . $divider . ",/";
$rrd_options .= " CDEF:" . $g_defname . $i . "max=" . $rrd['rra'] . $i . "max," . $divider . ",/";
$g_defname = $rrd['ds'] . "_cdef";
$rrd_options .= " CDEF:" . $g_defname . $i . "=" . $rrd['ds'] . $i . "," . $divider . ",/";
$rrd_options .= " CDEF:" . $g_defname . $i . "max=" . $rrd['ds'] . $i . "max," . $divider . ",/";
}
## Are our text values related to te multiplier/divisor or not?
if (isset($text_orig) && $text_orig)
{
$t_defname = $rrd['rra'];
$t_defname = $rrd['ds'];
} else {
$t_defname = $g_defname;
}
@ -65,7 +65,7 @@ foreach ($rrd_list as $i => $rrd)
$rrd_options .= " GPRINT:".$t_defname.$i.":LAST:%6.2lf%s".str_replace("%", "%%", $units)."";
$rrd_options .= " GPRINT:".$t_defname.$i."max:MAX:%6.2lf%s".str_replace("%", "%%", $units)."";
if (!$nototal) { $rrd_options .= " GPRINT:tot".$rrd['rra'].$i.":%6.2lf%s".str_replace("%", "%%", $total_units).""; }
if (!$nototal) { $rrd_options .= " GPRINT:tot".$rrd['ds'].$i.":%6.2lf%s".str_replace("%", "%%", $total_units).""; }
$rrd_options .= " COMMENT:'\\n'";
}

View File

@ -1,31 +1,31 @@
<?php
/// Draw generic bits graph
/// args: rra_in, rra_out, rrd_filename, bg, legend, from, to, width, height, inverse, percentile
/// args: ds_in, ds_out, rrd_filename, bg, legend, from, to, width, height, inverse, percentile
include("includes/graphs/common.inc.php");
$unit_text = str_pad(truncate($unit_text,18,''),18);
$line_text = str_pad(truncate($line_text,12,''),12);
$rrd_options .= " DEF:".$rra."=".$rrd_filename.":".$rra.":AVERAGE";
$rrd_options .= " DEF:".$rra."_max=".$rrd_filename.":".$rra.":MAX";
$rrd_options .= " DEF:".$ds."=".$rrd_filename.":".$ds.":AVERAGE";
$rrd_options .= " DEF:".$ds."_max=".$rrd_filename.":".$ds.":MAX";
if ($print_total)
{
$rrd_options .= " VDEF:".$rra."_total=rra,TOTAL";
$rrd_options .= " VDEF:".$ds."_total=ds,TOTAL";
}
if ($percentile)
{
$rrd_options .= " VDEF:".$rra."_percentile=".$rra.",".$percentile.",PERCENT";
$rrd_options .= " VDEF:".$ds."_percentile=".$ds.",".$percentile.",PERCENT";
}
if ($graph_max)
{
$rrd_options .= " AREA:".$rra."_max#".$colour_area_max.":";
$rrd_options .= " AREA:".$ds."_max#".$colour_area_max.":";
}
$rrd_options .= " AREA:".$rra."#".$colour_area.":";
$rrd_options .= " AREA:".$ds."#".$colour_area.":";
$rrd_options .= " COMMENT:'".$unit_text."Now Ave Max";
if ($percentile)
@ -34,14 +34,14 @@ if ($percentile)
}
$rrd_options .= "\\n'";
$rrd_options .= " LINE1.25:".$rra."#".$colour_line.":'".$line_text."'";
$rrd_options .= " GPRINT:".$rra.":LAST:%6.2lf%s";
$rrd_options .= " GPRINT:".$rra.":AVERAGE:%6.2lf%s";
$rrd_options .= " GPRINT:".$rra."_max:MAX:%6.2lf%s";
$rrd_options .= " LINE1.25:".$ds."#".$colour_line.":'".$line_text."'";
$rrd_options .= " GPRINT:".$ds.":LAST:%6.2lf%s";
$rrd_options .= " GPRINT:".$ds.":AVERAGE:%6.2lf%s";
$rrd_options .= " GPRINT:".$ds."_max:MAX:%6.2lf%s";
if ($percentile)
{
$rrd_options .= " GPRINT:".$rra."_percentile:%6.2lf%s";
$rrd_options .= " GPRINT:".$ds."_percentile:%6.2lf%s";
}
$rrd_options .= "\\\\n";
@ -49,12 +49,12 @@ $rrd_options .= " COMMENT:\\\\n";
if ($print_total)
{
$rrd_options .= " GPRINT:".$rra."_tot:Total\ %6.2lf%s\)\\\\l";
$rrd_options .= " GPRINT:".$ds."_tot:Total\ %6.2lf%s\)\\\\l";
}
if ($percentile)
{
$rrd_options .= " LINE1:".$rra."_percentile#aa0000";
$rrd_options .= " LINE1:".$ds."_percentile#aa0000";
}
?>

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "TunInOctets";
$rra_out = "TunOutOctets";
$ds_in = "TunInOctets";
$ds_out = "TunOutOctets";
include("includes/graphs/generic_bytes.inc.php");

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "TunInPkts";
$rra_out = "TunOutPkts";
$ds_in = "TunInPkts";
$ds_out = "TunOutPkts";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "IN";
$rra_out = "OUT";
$ds_in = "IN";
$ds_out = "OUT";
include("includes/graphs/generic_bits.inc.php");

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "PIN";
$rra_out = "POUT";
$ds_in = "PIN";
$ds_out = "POUT";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -18,8 +18,8 @@ foreach (explode(",", $id) as $ifid)
}
}
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
$colour_line_in = "006600";
$colour_line_out = "000099";

View File

@ -20,8 +20,8 @@ $multiplier = "8";
$colours_out = 'blues';
$nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
include("includes/graphs/generic_multi_bits_separated.inc.php");

View File

@ -4,11 +4,11 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safe
$rrd_list[0]['filename'] = $rrd_filename;
$rrd_list[0]['descr'] = "Downstream";
$rrd_list[0]['rra'] = "AturCurrAttainableR";
$rrd_list[0]['ds'] = "AturCurrAttainableR";
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = "Upstream";
$rrd_list[1]['rra'] = "AtucCurrAttainableR";
$rrd_list[1]['ds'] = "AtucCurrAttainableR";
$unit_text = "Bits/sec";

View File

@ -4,11 +4,11 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safe
$rrd_list[0]['filename'] = $rrd_filename;
$rrd_list[0]['descr'] = "Downstream";
$rrd_list[0]['rra'] = "AturCurrAtn";
$rrd_list[0]['ds'] = "AturCurrAtn";
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = "Upstream";
$rrd_list[1]['rra'] = "AtucCurrAtn";
$rrd_list[1]['ds'] = "AtucCurrAtn";
$unit_text = "dB";

View File

@ -4,11 +4,11 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safe
$rrd_list[0]['filename'] = $rrd_filename;
$rrd_list[0]['descr'] = "Downstream";
$rrd_list[0]['rra'] = "AturCurrOutputPwr";
$rrd_list[0]['ds'] = "AturCurrOutputPwr";
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = "Upstream";
$rrd_list[1]['rra'] = "AtucCurrOutputPwr";
$rrd_list[1]['ds'] = "AtucCurrOutputPwr";
$unit_text = "dBm";

View File

@ -4,11 +4,11 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safe
$rrd_list[0]['filename'] = $rrd_filename;
$rrd_list[0]['descr'] = "Downstream";
$rrd_list[0]['rra'] = "AturCurrSnrMgn";
$rrd_list[0]['ds'] = "AturCurrSnrMgn";
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = "Upstream";
$rrd_list[1]['rra'] = "AtucCurrSnrMgn";
$rrd_list[1]['ds'] = "AtucCurrSnrMgn";
$unit_text = "dB";

View File

@ -4,11 +4,11 @@ $rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safe
$rrd_list[0]['filename'] = $rrd_filename;
$rrd_list[0]['descr'] = "Downstream";
$rrd_list[0]['rra'] = "AturChanCurrTxRate";
$rrd_list[0]['ds'] = "AturChanCurrTxRate";
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = "Upstream";
$rrd_list[1]['rra'] = "AtucChanCurrTxRate";
$rrd_list[1]['ds'] = "AtucChanCurrTxRate";
$unit_text = "Bits/sec";

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
include("includes/graphs/generic_bits.inc.php");

View File

@ -2,16 +2,16 @@
$rrd_list[1]['filename'] = $rrd_filename;
$rrd_list[1]['descr'] = $int['ifDescr'];
$rrd_list[1]['rra_in'] = "INERRORS";
$rrd_list[1]['rra_out'] = "OUTERRORS";
$rrd_list[1]['ds_in'] = "INERRORS";
$rrd_list[1]['ds_out'] = "OUTERRORS";
$rrd_list[1]['descr'] = "Errors";
$rrd_list[1]['colour_area_in'] = "FF3300";
$rrd_list[1]['colour_area_out'] = "FF6633";
$rrd_list[4]['filename'] = $rrd_filename;
$rrd_list[4]['descr'] = $int['ifDescr'];
$rrd_list[4]['rra_in'] = "INDISCARDS";
$rrd_list[4]['rra_out'] = "OUTDISCARDS";
$rrd_list[4]['ds_in'] = "INDISCARDS";
$rrd_list[4]['ds_out'] = "OUTDISCARDS";
$rrd_list[4]['descr'] = "Discards";
$rrd_list[4]['colour_area_in'] = "805080";
$rrd_list[4]['colour_area_out'] = "c0a060";

View File

@ -15,10 +15,10 @@ if (is_file($rrd_filename))
foreach ($oids as $oid)
{
$oid = str_replace("dot3Stats", "", $oid);
$oid_rra = truncate($oid, 19, '');
$oid_ds = truncate($oid, 19, '');
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $oid;
$rrd_list[$i]['rra'] = $oid_rra;
$rrd_list[$i]['ds'] = $oid_ds;
$i++;
}
}

View File

@ -5,24 +5,24 @@ if (1)
{
# $rrd_list[1]['filename'] = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safename($port['ifIndex'] . ".rrd");
# $rrd_list[1]['descr'] = $int['ifDescr'];
# $rrd_list[1]['rra_in'] = "INNUCASTPKTS";
# $rrd_list[1]['rra_out'] = "OUTNUCASTPKTS";
# $rrd_list[1]['ds_in'] = "INNUCASTPKTS";
# $rrd_list[1]['ds_out'] = "OUTNUCASTPKTS";
# $rrd_list[1]['descr'] = "NonUnicast";
# $rrd_list[1]['colour_area_in'] = "BB77BB";
# $rrd_list[1]['colour_area_out'] = "FFDD88";
$rrd_list[2]['filename'] = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safename($port['ifIndex'] . ".rrd");
$rrd_list[2]['descr'] = $int['ifDescr'];
$rrd_list[2]['rra_in'] = "INBROADCASTPKTS";
$rrd_list[2]['rra_out'] = "OUTBROADCASTPKTS";
$rrd_list[2]['ds_in'] = "INBROADCASTPKTS";
$rrd_list[2]['ds_out'] = "OUTBROADCASTPKTS";
$rrd_list[2]['descr'] = "Broadcast";
$rrd_list[2]['colour_area_in'] = "aa37BB";
$rrd_list[2]['colour_area_out'] = "ee9D88";
$rrd_list[4]['filename'] = $config['rrd_dir'] . "/" . $device['hostname'] . "/port-" . safename($port['ifIndex'] . ".rrd");
$rrd_list[4]['descr'] = $int['ifDescr'];
$rrd_list[4]['rra_in'] = "INMULTICASTPKTS";
$rrd_list[4]['rra_out'] = "OUTMULTICASTPKTS";
$rrd_list[4]['ds_in'] = "INMULTICASTPKTS";
$rrd_list[4]['ds_out'] = "OUTMULTICASTPKTS";
$rrd_list[4]['descr'] = "Multicast";
$rrd_list[4]['colour_area_in'] = "905090";
$rrd_list[4]['colour_area_out'] = "c0a060";
@ -42,8 +42,8 @@ elseif (is_file($config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename(
{
$rrd_filename = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename($port['ifIndex'] . ".rrd");
$rra_in = "INNUCASTPKTS";
$rra_out = "OUTNUCASTPKTS";
$ds_in = "INNUCASTPKTS";
$ds_out = "OUTNUCASTPKTS";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -20,8 +20,8 @@ $multiplier = "8";
$colours_out = 'blues';
$nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
$ds_in = "INOCTETS";
$ds_out = "OUTOCTETS";
include("includes/graphs/generic_multi_bits_separated.inc.php");

View File

@ -1,7 +1,7 @@
<?php
$rra_in = "INUCASTPKTS";
$rra_out = "OUTUCASTPKTS";
$ds_in = "INUCASTPKTS";
$ds_out = "OUTUCASTPKTS";
$colour_area_in = "AA66AA";
$colour_line_in = "330033";

View File

@ -8,15 +8,15 @@ $file = $config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename("screeno
$rrd_list[0]['filename'] = $file;
$rrd_list[0]['descr'] = "Maxiumum";
$rrd_list[0]['rra'] = "max";
$rrd_list[0]['ds'] = "max";
$rrd_list[1]['filename'] = $file;
$rrd_list[1]['descr'] = "Allocated";
$rrd_list[1]['rra'] = "allocate";
$rrd_list[1]['ds'] = "allocate";
$rrd_list[2]['filename'] = $file;
$rrd_list[2]['descr'] = "Failed";
$rrd_list[2]['rra'] = "failed";
$rrd_list[2]['ds'] = "failed";
if ($_GET['debug']) { print_r($rrd_list); }