首页 >函数列表 >snmp_read_mib

snmp_read_mib

snmp_read_mib

(PHP 5)

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.

范例

Example #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_rsnmprealwalk('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
)


  • snmp2_get
  • snmp2_getnext
  • snmp2_real_walk
  • snmp2_set
  • snmp2_walk
  • snmp3_get
  • snmp3_getnext
  • snmp3_real_walk
  • snmp3_set
  • snmp3_walk
  • snmpget
  • snmpgetnext
  • snmprealwalk
  • snmpset
  • snmpwalk
  • snmpwalkoid
  • snmp_get_quick_print
  • snmp_get_valueretrieval
  • snmp_read_mib
  • snmp_set_enum_print
  • snmp_set_oid_numeric_print
  • snmp_set_oid_output_format
  • snmp_set_quick_print
  • snmp_set_valueretrieval
  • PHP MySQL HTML CSS JavaScript MSSQL AJAX .NET JSP Linux Mac ASP 服务器 SQL jQuery C# C++ java Android IOS oracle MongoDB SQLite wamp 交通频道