diff --git a/discovery.php b/discovery.php index 591862401..509d41a7a 100755 --- a/discovery.php +++ b/discovery.php @@ -63,6 +63,11 @@ while ($device = mysql_fetch_array($device_query)) { } + if($device['os'] == "JunOS") { + include("includes/discovery/bgp-peers.php"); + } + + if($device['os'] == "IOS" || $device['os'] == "IOS XE") { include("includes/discovery/cisco-vlans.php"); include("includes/discovery/cisco-physical.php"); diff --git a/includes/discovery/bgp-peers.php b/includes/discovery/bgp-peers.php index 28aa245dd..4219625bd 100755 --- a/includes/discovery/bgp-peers.php +++ b/includes/discovery/bgp-peers.php @@ -19,8 +19,8 @@ $peers = trim(str_replace("BGP4-MIB::bgpPeerRemoteAs.", "", `$peers_cmd`)); foreach (explode("\n", $peers) as $peer) { - if($peer) { - list($peer_ip, $peer_as) = split(" ", $peer); + list($peer_ip, $peer_as) = split(" ", $peer); + if($peer && $peer_ip != "0.0.0.0") { $peerlist[] = $device['device_id'] ." $peer_ip";