mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Implements the CISCO-OTV-MIB to retrieve OTV counters from Cisco devices. This collects information on the configured Overlays and Adjacencies Statistics are collected for the amount of VLAN's on each overlay and the amount of MAC addresses available over each OTV endpoint. OTV alerts are collected and generated if the appropriate alerting rules exist. Data is displayed under routing at both the global and device level. Includes function snmpwalk_array_num, which performs a numeric SNMPWalk and returns an array containing $count indexes One Index: From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27.18']['655360'] = 0 Two Indexes: From: 1.3.6.1.4.1.9.9.166.1.15.1.1.27.18.655360 = 0 To: $array['1.3.6.1.4.1.9.9.166.1.15.1.1.27']['18']['655360'] = 0 And so on...
65 lines
1.4 KiB
PHP
65 lines
1.4 KiB
PHP
<?php
|
|
|
|
$pagetitle[] = 'Routing';
|
|
|
|
if ($_GET['optb'] == 'graphs' || $_GET['optc'] == 'graphs') {
|
|
$graphs = 'graphs';
|
|
}
|
|
else {
|
|
$graphs = 'nographs';
|
|
}
|
|
|
|
// $datas[] = 'overview';
|
|
// $routing_count is populated by print-menubar.inc.php
|
|
// $type_text['overview'] = "Overview";
|
|
$type_text['bgp'] = 'BGP';
|
|
$type_text['cef'] = 'CEF';
|
|
$type_text['ospf'] = 'OSPF';
|
|
$type_text['vrf'] = 'VRFs';
|
|
$type_text['cisco-otv'] = 'OTV';
|
|
|
|
print_optionbar_start();
|
|
|
|
// if (!$vars['protocol']) { $vars['protocol'] = "overview"; }
|
|
echo "<span style='font-weight: bold;'>Routing</span> » ";
|
|
|
|
unset($sep);
|
|
foreach ($routing_count as $type => $value) {
|
|
if (!$vars['protocol']) {
|
|
$vars['protocol'] = $type;
|
|
}
|
|
|
|
echo $sep;
|
|
unset($sep);
|
|
|
|
if ($vars['protocol'] == $type) {
|
|
echo '<span class="pagemenu-selected">';
|
|
}
|
|
|
|
if ($routing_count[$type]) {
|
|
echo generate_link($type_text[$type].' ('.$routing_count[$type].')', array('page' => 'routing', 'protocol' => $type));
|
|
$sep = ' | ';
|
|
}
|
|
|
|
if ($vars['protocol'] == $type) {
|
|
echo '</span>';
|
|
}
|
|
}//end foreach
|
|
|
|
print_optionbar_end();
|
|
|
|
switch ($vars['protocol']) {
|
|
case 'overview':
|
|
case 'bgp':
|
|
case 'vrf':
|
|
case 'cef':
|
|
case 'ospf':
|
|
case 'cisco-otv':
|
|
include 'pages/routing/'.$vars['protocol'].'.inc.php';
|
|
break;
|
|
|
|
default:
|
|
echo report_this('Unknown protocol '.$vars['protocol']);
|
|
break;
|
|
}
|