more hardware detection - discovering the internets :)

git-svn-id: http://www.observium.org/svn/observer/trunk@1382 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-07-17 17:26:47 +00:00
parent 8f76f5922f
commit 67b9345005
21 changed files with 121 additions and 22 deletions
+1 -1
View File
@@ -331,7 +331,7 @@ a.list-device-ignored-up {
}
a.list-device-disabled {
color: #888888;
color: #999999;
}
.footer-text {

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 567 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 964 B

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

+1 -1
View File
@@ -6,7 +6,7 @@ if ($config['enable_printers'])
echo("Toner : ");
if ($device['os'] == "dell-laser" || $device['os'] == "jetdirect")
if ($device['os_group'] == 'printer')
{
$oids = trim(snmp_walk($device, "SNMPv2-SMI::mib-2.43.12.1.1.2.1 ", "-OsqnU"));
if ($debug) { echo($oids."\n"); }
@@ -1,10 +0,0 @@
<?php
if(!$os) {
if(strpos($sysDescr, "DES-") !== FALSE) { $os = "dlink"; }
}
?>
+20
View File
@@ -0,0 +1,20 @@
<?php
if (!$os) {
if (preg_match("/D-Link .* AP/", $sysDescr)) { $os = "dlinkap"; }
else if (preg_match("/D-Link Access Point/", $sysDescr)) { $os = "dlinkap"; }
}
?>
<?php
if (!$os) {
if (preg_match("/D-Link .* AP/", $sysDescr)) { $os = "dlinkap"; }
else if (preg_match("/D-Link Access Point/", $sysDescr)) { $os = "dlinkap"; }
}
?>
+10
View File
@@ -0,0 +1,10 @@
<?php
if(!$os) {
if(strpos($sysDescr, "ZyXEL IES-") !== FALSE) { $os = "ies"; }
}
?>
+9
View File
@@ -0,0 +1,9 @@
<?php
if(!$os) {
if(strstr($sysDescr, "KONICA MINOLTA magicolor")) { $os = "konica"; }
}
?>
@@ -0,0 +1,9 @@
<?php
if(!$os) {
if(strstr($sysDescr, "KYOCERA ")) { $os = "kyocera"; }
}
?>
@@ -2,9 +2,9 @@
if (!$os)
{
if (strstr($sysDescr, "Neyland 24T")) { $os = "powerconnect"; }
if (stristr($sysDescr, "PowerConnect ")) { $os = "powerconnect"; }
if (preg_match("/Dell.*Gigabit\ Ethernet/i",$sysDescr)) { $os = "powerconnect"; }
if (strstr($sysDescr, "Neyland 24T")) { $os = "powerconnect"; } /* Powerconnect 5324 */
else if (stristr($sysDescr, "PowerConnect ")) { $os = "powerconnect"; }
else if (preg_match("/Dell.*Gigabit\ Ethernet/i",$sysDescr)) { $os = "powerconnect"; }
}
?>
@@ -0,0 +1,10 @@
<?php
if (!$os) {
if (preg_match("/^Prestige \d/", $sysDescr)) { $os = "prestige"; }
else if (preg_match("/^P-.*-/", $sysDescr)) { $os = "prestige"; }
}
?>
+1 -1
View File
@@ -2,7 +2,7 @@
if(!$os) {
if(strstr($sysDescr, "ProCurve")) { $os = "procurve"; }
if(stristr($sysDescr, "ProCurve")) { $os = "procurve"; }
}
+9
View File
@@ -0,0 +1,9 @@
<?php
if(!$os) {
if(strstr($sysDescr, "RICOH Aficio")) { $os = "ricoh"; }
}
?>
@@ -4,6 +4,7 @@ if(!$os) {
if(strpos($sysDescr, "TG585v7") !== FALSE) { $os = "speedtouch"; }
else if(strpos($sysDescr, "SpeedTouch 5") !== FALSE) { $os = "speedtouch"; }
else if (preg_match("/^ST\d/", $sysDescr)) { $os = "speedtouch"; }
}
+2 -1
View File
@@ -4,6 +4,7 @@
if(strstr($sysDescr, "x86")) { $hardware = "Generic x86"; }
if(strstr($sysDescr, "AMD64")) { $hardware = "Generic x64"; }
if(strstr($sysDescr, "Intel64")) { $hardware = "Generic x64"; }
if(strstr($sysDescr, "Build Number: 1381")) { $version = "NT 4.0"; }
if(strstr($sysDescr, "Build 2195")) { $version = "2000 (NT 5.0)"; }
@@ -12,7 +13,7 @@
if(strstr($sysDescr, "Build 6000")) { $version = "Vista (NT 6.0)"; }
if(strstr($sysDescr, "Build 6001")) { $version = "Vista SP1 / 2008 (NT 6.0)"; }
if(strstr($sysDescr, "Build 6001")) { $version = "Vista SP2 / 2008 SP2 (NT 6.0)"; }
if(strstr($sysDescr, "Build 6001")) { $version = "7 / 2008 R2 (NT 6.1)"; }
if(strstr($sysDescr, "Build 7600")) { $version = "7 / 2008 R2 (NT 6.1)"; }
if(strstr($sysDescr, "Uniprocessor Free")) { $features = "Uniprocessor"; }
if(strstr($sysDescr, "Multiprocessor Free")) { $features = "Multiprocessor"; }
+44 -4
View File
@@ -100,10 +100,13 @@ $config['os']['extremeware']['ifname'] = 1;
$config['os']['powerconnect']['text'] = "Dell PowerConnect";
$config['os']['powerconnect']['ifname'] = 1;
$config['os']['powerconnect']['type'] = "network";
$config['os']['powerconnect']['icon'] = "dell";
$config['os']['powervault']['text'] = "Dell PowerVault";
$config['os']['powervault']['icon'] = "dell";
$config['os']['drac']['text'] = "Dell DRAC";
$config['os']['drac']['icon'] = "dell";
$config['os']['bcm963']['text'] = "Broadcom BCM963xxx";
$config['os']['bcm963']['icon'] = "broadcom";
@@ -111,6 +114,14 @@ $config['os']['bcm963']['icon'] = "broadcom";
$config['os']['netopia']['text'] = "Motorola Netopia";
$config['os']['netopia']['type'] = "network";
$config['os']['dlink']['text'] = "D-Link Switch";
$config['os']['dlink']['type'] = "network";
$config['os']['dlink']['icon'] = "dlink";
$config['os']['dlinkap']['text'] = "D-Link Access Point";
$config['os']['dlinkap']['type'] = "network";
$config['os']['dlink']['icon'] = "dlink";
$config['os']['axiscam']['text'] = "AXIS Network Camera";
$config['os']['axisdocserver']['text'] = "AXIS Network Document Server";
@@ -135,6 +146,15 @@ $config['os']['zywall']['text'] = "ZyXEL ZyWALL";
$config['os']['zywall']['type'] = "firewall";
$config['os']['zywall']['overgraph'][] = "device_bits";
$config['os']['zywall']['overtext'] = "Traffic";
$config['os']['zywall']['icon'] = "zyxel";
$config['os']['prestige']['text'] = "ZyXEL Prestige";
$config['os']['prestige']['type'] = "network";
$config['os']['prestige']['icon'] = "zyxel";
$config['os']['ies']['text'] = "ZyXEL IES DSLAM";
$config['os']['ies']['type'] = "network";
$config['os']['ies']['icon'] = "zyxel";
$config['os']['allied']['text'] = "AlliedWare";
$config['os']['allied']['type'] = "network";
@@ -193,10 +213,30 @@ $config['os']['jetdirect']['overtext'] = "Toner";
$config['os']['jetdirect']['ifname'] = 1;
$config['os']['jetdirect']['type'] = "printer";
$config['os']['3com']['text'] = "3Com";
$config['os']['3com']['overgraph'][] = "";
$config['os']['3com']['overtext'] = "";
$config['os']['3com']['type'] = "network";
$config['os']['ricoh']['group'] = "printer";
$config['os']['ricoh']['text'] = "Ricoh Printer";
$config['os']['ricoh']['overgraph'][] = "device_toner";
$config['os']['ricoh']['overtext'] = "Toner";
$config['os']['ricoh']['type'] = "printer";
$config['os']['konica']['group'] = "printer";
$config['os']['konica']['text'] = "Konica-Minolta Printer";
$config['os']['konica']['overgraph'][] = "device_toner";
$config['os']['konica']['overtext'] = "Toner";
$config['os']['konica']['ifname'] = 1;
$config['os']['konica']['type'] = "printer";
$config['os']['kyocera']['group'] = "printer";
$config['os']['kyocera']['text'] = "Kyocera Mita Printer";
$config['os']['kyocera']['overgraph'][] = "device_toner";
$config['os']['kyocera']['overtext'] = "Toner";
$config['os']['kyocera']['ifname'] = 1;
$config['os']['kyocera']['type'] = "printer";
$config['os']['3com']['text'] = "3Com";
$config['os']['3com']['overgraph'][] = "";
$config['os']['3com']['overtext'] = "";
$config['os']['3com']['type'] = "network";
if(!$config['graph_colours']['greens']) {
$config['graph_colours']['greens'] = array('B6D14B','91B13C','6D912D','48721E','24520F','003300');