nms nms nms

git-svn-id: http://www.observium.org/svn/observer/trunk@1331 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-07-10 12:17:58 +00:00
parent d3c2f2b5e4
commit 5cb291d954
8 changed files with 17 additions and 17 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ LM-Sensors setup
For lm-sensors/net-snmp to put your temperatures in the "Temp" group (as
opposed to the "Misc" group, their name needs to start with "temp"; for
Observer to see the interface the name should start with "temp-" (i.e.
ObserverNMS to see the interface the name should start with "temp-" (i.e.
temp-CPU, temp-System). You can change this in /etc/sensors.conf - change
the label descriptions if necessary, under your specific chipset block.
+3 -3
View File
@@ -18,7 +18,7 @@ Please see COPYING for usage requirements and restrictions.
Introduction
------------
Observer is an auto-discovering network monitoring system.
ObserverNMS is an auto-discovering network monitoring system.
It's designed to be an easily-navigable interface to the health of your network.
@@ -30,12 +30,12 @@ Planned Features
* Pseudowire (MPLS/L2TP) tracking * In Progress
* MPLS IP-VPN tracking * In Progress
* 95th and metered usage tracking * In Progress
* Nagios Integration * Too scary for contempation
* Nagios Integration * Too scary for contemplation
Installation
------------
Installation of Observer is currently not for the faint of heart! There is no automated
Installation of ObserverNMS is currently not for the faint of heart! There is no automated
install script, so it'll probably take quite a bit of fiddling!
Please see http://www.observernms.org.
+1 -1
View File
@@ -10,7 +10,7 @@
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
--
-- Database: `observer`
-- Database: `observernms`
--
-- --------------------------------------------------------
+3 -3
View File
@@ -128,11 +128,11 @@ print_optionbar_end(); ?>
<?php
$observer_version = $config['version'];
$observernms_version = $config['version'];
if (file_exists('.svn/entries'))
{
$svn = File('.svn/entries');
$observer_version .='-SVN r' . trim($svn[3]);
$observernms_version .='-SVN r' . trim($svn[3]);
unset($svn);
}
@@ -152,7 +152,7 @@ print_optionbar_start(NULL);
echo("
<h3>Versions</h3>
<table width=100% cellpadding=3 cellspacing=0 border=0>
<tr valign=top><td width=150><b>ObserverNMS</b></td><td>$observer_version</td></tr>
<tr valign=top><td width=150><b>ObserverNMS</b></td><td>$observernms_version</td></tr>
<tr valign=top><td><b>Apache</b></td><td>$apache_version</td></tr>
<tr valign=top><td><b>PHP</b></td><td>$php_version</td></tr>
<tr valign=top><td><b>MySQL</b></td><td>$mysql_version</td></tr>
@@ -5,7 +5,7 @@ global $valid_temp;
if($device['os_group'] == "unix")
{
# FIXME snmp_walk
# Observer-style temperature
# ObserverNMS-style temperature
$oids = shell_exec($config['snmpwalk'] . " -M " . $config['mibdir'] . " -M " . $config['mibdir'] . " -".$device['snmpver']." -m SNMPv2-SMI -Osqn -CI -c ".$device['community']." ".$device['hostname'].":".$device['port']." .1.3.6.1.4.1.2021.7891 | sed s/.1.3.6.1.4.1.2021.7891.// | grep '.1.1 ' | grep -v '.101.' | cut -d'.' -f 1");
$oids = trim($oids);
if ($oids) echo("Observer-Style ");
@@ -18,7 +18,7 @@ if($device['os_group'] == "unix")
$descr_query = $config['snmpget'] . " -M " . $config['mibdir'] . " -".$device['snmpver']." -m SNMPv2-SMI -Osqn -c ".$device['community']." ".$device['hostname'].":".$device['port']." .1.3.6.1.4.1.2021.7891.$oid.2.1 | sed s/.1.3.6.1.4.1.2021.7891.$oid.2.1\ //";
$descr = trim(str_replace("\"", "", shell_exec($descr_query)));
$fulloid = ".1.3.6.1.4.1.2021.7891.$oid.101.1";
discover_temperature($valid_temp, $device, $fulloid, $oid, "observer", $descr, "1", NULL, NULL, NULL);
discover_temperature($valid_temp, $device, $fulloid, $oid, "observernms", $descr, "1", NULL, NULL, NULL);
}
}
}
+1 -1
View File
@@ -1,7 +1,7 @@
<?php
## Very basic parser to parse classic Observer-type schemes.
## Very basic parser to parse classic ObserverNMS-type schemes.
## Parser should populate $port_ifAlias array with type, descr, circuit, speed and notes
unset ($port_ifAlias);
+4 -4
View File
@@ -216,13 +216,13 @@ if(isset($_SERVER['HTTPS'])) {
}
### Connect to database
$observer_link = mysql_pconnect($config['db_host'], $config['db_user'], $config['db_pass']);
if (!$observer_link) {
echo "<h2>MySQL Error</h2>";
$observernms_link = mysql_pconnect($config['db_host'], $config['db_user'], $config['db_pass']);
if (!$observernms_link) {
echo "<h2>ObserverNMS MySQL Error</h2>";
echo mysql_error();
die;
}
$observer_db = mysql_select_db($config['db_name'], $observer_link);
$observernms_db = mysql_select_db($config['db_name'], $observernms_link);
# Set some times needed by loads of scripts (it's dynamic, so we do it here!)
+2 -2
View File
@@ -9,7 +9,7 @@ include("includes/discovery/functions.inc.php");
include_once('Net/SmartIRC.php');
class observerbot
class observernmsbot
{
function device_info (&$irc, &$data)
@@ -52,7 +52,7 @@ $port = 6667;
$nick = "ObserverBOT";
$chan = "#observernms";
$bot = &new observerbot( );
$bot = &new observernmsbot( );
$irc = &new Net_SmartIRC( );
$irc->setUseSockets( TRUE );