PHP  
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
search for in the  
<simplexml_load_stringsnmp_get_quick_print>
Last updated: Mon, 16 Jul 2012

CXXIII. SNMP 函数库

需求

为了在 Unix 中使用 SNMP 函数库,您需要安装 UCD SNMPNET-SNMP 包。在 Windows 中,这些函数只能用于 NT,而不能用于 Win95/98。

安装

重点:为了使用 UCD SNMP 包,您需要在编译之前将 NO_ZEROLENGTH_COMMUNITY 定义为 1。 在 configuring UCD SNMP 之后,编辑 config.h,查找 NO_ZEROLENGTH_COMMUNITY,将 #define 所在行的注释去掉。修改后应该类似这样:
#define NO_ZEROLENGTH_COMMUNITY 1
然后使用 --with-snmp[=DIR] 选项编译 PHP。

如果您在联合 SNMP 命令时看到奇怪的分段错误,则不要继续上述的指令。如果您不想重新编译 UCD SNMP,可以使用 --enable-ucd-snmp-hack 开关编译 PHP,此开关将避开上述错误。

Windows 版本在目录 mibs 中包含了支持 SNMP 的文件。此目录应该移到 DRIVE:\usr\mibs,其中 DRIVE 是安装 PHP 所在的驱动器名,例如:c:\usr\mibs

运行时配置

本扩展模块在 php.ini 中未定义任何设置指令。

预定义常量

本扩展模块未定义任何常量。

目录
snmp_get_quick_print --  返回 UCD 库中 quick_print 设置的当前值
snmp_get_valueretrieval --  Return the method how the SNMP values will be returned
snmp_read_mib --  Reads and parses a MIB file into the active MIB tree
snmp_set_enum_print --  Return all values that are enums with their enum value instead of the raw integer
snmp_set_oid_numeric_print --  Return all objects including their respective object id within the specified one
snmp_set_quick_print --  设置 UCD SNMP 库中 quick_print 的值
snmp_set_valueretrieval --  Specify the method how the SNMP values will be returned
snmpget -- 获取一个 SNMP 对象
snmpgetnext --  Fetch a SNMP object
snmprealwalk --  返回指定的所有对象,包括它们各自的对象 ID
snmpset -- 设置一个 SNMP 对象
snmpwalk -- 从代理返回所有的 SNMP 对象
snmpwalkoid -- 查询关于网络实体的信息树



<simplexml_load_stringsnmp_get_quick_print>
 Last updated: Mon, 16 Jul 2012
 
Copyright © 2001-2005 The PHP Group
All rights reserved.
This unofficial mirror is operated at: http://manual.phpv.net/
Last updated: Thu Jul 7 19:13:47 2005 CST