mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
routing overview start
git-svn-id: http://www.observium.org/svn/observer/trunk@2177 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
14
html/pages/device/routing/overview/bgp.inc.php
Normal file
14
html/pages/device/routing/overview/bgp.inc.php
Normal file
@@ -0,0 +1,14 @@
|
||||
|
||||
<?php
|
||||
|
||||
echo("<strong>AS".$device['bgpLocalAs']."</strong>");
|
||||
|
||||
echo("<br />");
|
||||
|
||||
$total = mysql_result(mysql_query("SELECT count(*) FROM `bgpPeers` WHERE `device_id` = '".$device['device_id']."'"),0);
|
||||
$up = mysql_result(mysql_query("SELECT count(*) FROM `bgpPeers` WHERE `device_id` = '".$device['device_id']."' AND `bgpPeerState` = 'established'"),0);
|
||||
$stop = mysql_result(mysql_query("SELECT count(*) FROM `bgpPeers` WHERE `device_id` = '".$device['device_id']."' AND `bgpPeerAdminStatus` = 'stop'"),0);
|
||||
|
||||
echo("Sessions: ".$total." Up: ".$up." Down: ".($total-$up) . ($stop != 0 ? " ( Shutdown: ".$stop." )" : ""));
|
||||
|
||||
?>
|
5
html/pages/device/routing/overview/ospf.inc.php
Normal file
5
html/pages/device/routing/overview/ospf.inc.php
Normal file
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
echo("<pre>");
|
||||
print_r(mysql_fetch_assoc(mysql_query("SELECT * FROM `ospf_instances` WHERE `device_id` = '".$device['device_id']."'")));
|
||||
echo("</pre>");
|
||||
?>
|
Reference in New Issue
Block a user