Merge pull request #1184 from laf/issue-936

Updated BGP polling for Cisco to support CISCO-BGP4-MIB better
This commit is contained in:
Paul Gear
2015-06-13 10:20:58 +10:00
6 changed files with 2438 additions and 1166 deletions
+7 -4
View File
@@ -1,7 +1,3 @@
<div style='padding: 10px; height: 20px; clear: both; display: block;'>
<div style='float: left; font-size: 22px; font-weight: bold;'>Local AS : <?php echo($device['bgpLocalAs']); ?></div>
</div>
<?php
$link_array = array('page' => 'device',
@@ -13,6 +9,8 @@ if(!isset($vars['view'])) { $vars['view'] = "basic"; }
print_optionbar_start();
echo "<strong>Local AS : " .$device['bgpLocalAs']."</strong> ";
echo("<span style='font-weight: bold;'>BGP</span> &#187; ");
if ($vars['view'] == "basic") { echo("<span class='pagemenu-selected'>"); }
@@ -126,6 +124,11 @@ foreach (dbFetchRows("SELECT * FROM `bgpPeers` WHERE `device_id` = ? ORDER BY `b
unset($sep);
if (filter_var($peer['bgpLocalAddr'], FILTER_VALIDATE_IP, FILTER_FLAG_IPV6) !== FALSE) {
$peer['bgpPeerIdentifier'] = Net_IPv6::compress($peer['bgpPeerIdentifier']);
}
$graph_type = "bgp_updates";
$peer_daily_url = "graph.php?id=" . $peer['bgpPeer_id'] . "&amp;type=" . $graph_type . "&amp;from=".$config['time']['day']."&amp;to=".$config['time']['now']."&amp;width=500&amp;height=150";
$peeraddresslink = "<span class=list-large><a onmouseover=\"return overlib('<img src=\'$peer_daily_url\'>', LEFT".$config['overlib_defaults'].");\" onmouseout=\"return nd();\">" . $peer['bgpPeerIdentifier'] . "</a></span>";