Split VMware into seperate OS (#12243)

* Split VMware into separate OS

* Bump VMware MIBs
This commit is contained in:
Jellyfrog
2020-11-03 21:27:23 +01:00
committed by GitHub
parent fafbf0a221
commit 28591c0330
26 changed files with 10312 additions and 610 deletions

View File

@@ -1,5 +1,6 @@
<?php
use Illuminate\Support\Str;
use LibreNMS\Config;
$hrstorage_array = snmpwalk_cache_oid($device, 'hrStorageEntry', null, 'HOST-RESOURCES-MIB:HOST-RESOURCES-TYPES:NetWare-Host-Ext-MIB');
@@ -36,7 +37,7 @@ if (is_array($hrstorage_array)) {
continue;
}
if ($device['os'] == 'vmware' && $descr == 'Real Memory') {
if (Str::startsWith($device['os'], 'vmware') && $descr == 'Real Memory') {
$old_rrdfile = ['storage', 'hrstorage', $descr];
$new_rrdfile = ['mempool', 'hrstorage', $storage['hrStorageIndex']];
rrd_file_rename($device, $old_rrdfile, $new_rrdfile);