Рекурсивный акроним словосочетания «PHP: Hypertext Preprocessor»
Добро пожаловать на форум PHP программистов!
За последние 24 часа нас посетил 16141 программист и 1772 робота. Сейчас ищут 1917 программистов ...
snmp_read_mib - Reads and parses a MIB file into the active MIB tree
Вернуться к: SNMP Функции
snmp_read_mib
(PHP 5, PHP 7)
snmp_read_mib — Reads and parses a MIB file into the active MIB tree
Описание
bool snmp_read_mib
( string
$filename
)This function is used to load additional, e.g. vendor specific, MIBs so that human readable OIDs like VENDOR-MIB::foo.1 instead of error prone numeric OIDs can be used.
The order in which the MIBs are loaded does matter as the underlying Net-SNMP libary will print warnings if referenced objects cannot be resolved.
Список параметров
-
filename
-
The filename of the MIB.
Примеры
Пример #1 Using snmp_read_mib()
<?php
print_r( snmprealwalk('localhost', 'public', '.1.3.6.1.2.1.2.3.4.5') );
snmp_read_mib('./FOO-BAR-MIB.txt');
print_r( snmprealwalk('localhost', 'public', 'FOO-BAR-MIB::someTable' );
?>
The above example is made up but the results would look like:
Array ( [iso.3.6.1.2.1.2.3.4.5.0] => Gauge32: 6 ) Array ( [FOO-BAR-MIB::someTable.0] => Gauge32: 6 )
Вернуться к: SNMP Функции