mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
* Fix os additional information for several OS. $poll_device is not available, use $device * fix draytek test data
21 lines
916 B
PHP
21 lines
916 B
PHP
<?php
|
|
|
|
$hardware = snmp_get($device, 'sysObjectID.0', '-Oqvs', 'FOUNDRY-SN-AGENT-MIB:FOUNDRY-SN-ROOT-MIB');
|
|
|
|
$hardware = rewrite_ironware_hardware($hardware);
|
|
|
|
$version = snmp_get($device, 'snAgBuildVer.0', '-Oqvs', 'FOUNDRY-SN-AGENT-MIB:FOUNDRY-SN-ROOT-MIB');
|
|
|
|
if (strpos($version, '.')) {
|
|
$version = str_replace('V', '', $version);
|
|
$version = str_replace('"', '', $version);
|
|
} else {
|
|
// Brocade NetIron CER, Extended route scalability, IronWare Version V5.6.0fT183 Compiled on Mar 27 2015 at 02:13:25 labeled as V5.6.00fb
|
|
// Brocade MLXe (System Mode: XMR), IronWare Version V5.6.0gT163 Compiled on Aug 27 2015 at 23:23:54 labeled as V5.6.00g
|
|
preg_match('/IronWare Version (.*) Compiled on/', $device['sysDescr'], $regexp_result);
|
|
$version = $regexp_result[1];
|
|
$version = str_replace('V', '', $version);
|
|
}
|
|
|
|
$serial = snmp_get($device, 'snChasSerNum.0', '-Ovq', 'FOUNDRY-SN-AGENT-MIB');
|