Files
Jellyfrog 31a237b114 Miscellaneous cleanup - part 3 (#14450)
* Miscellaneous cleanup - part 3

* Apply fixes from StyleCI
2022-10-19 00:34:19 +02:00

14 lines
433 B
PHP

<?php
if (! isset($storage_cache['dsk'])) {
$storage_cache['dsk'] = snmpwalk_cache_oid($device, 'dskTable', null, 'UCD-SNMP-MIB');
d_echo($storage_cache);
}
$entry = $storage_cache['dsk'][$storage['storage_index']];
$storage['units'] = 1024;
$storage['size'] = ($entry['dskTotal'] * $storage['units']);
$storage['free'] = ($entry['dskAvail'] * $storage['units']);
$storage['used'] = ($storage['size'] - $storage['free']);