|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2006-08-20 03:08 UTC] larryjadams at comcast dot net
Description:
------------
The snmpgetnext function does not work in the PHP distributions. This has been an issue for a while, but I am just getting around to publishing the bug. Sorry...
Reproduce code:
---------------
<?php
print snmp2_getnext("localhost","pubilc",".1.3.6.1.2");
?>
or
<?php
print snmpgetnext("localhost","pubilc",".1.3.6.1.2");
?>
Expected result:
----------------
If you run the following command:
snmpgetnext -v 1 -c public localhost you would get
.1.3.6.1.2.1.1.1.0 = STRING: Hardware: x86 Family 6 Model 13 Stepping 8 AT/AT COMPATIBLE - Software: Windows 2000 Versio
n 5.1 (Build 2600 Uniprocessor Free)
Actual result:
--------------
Warning: snmp2_getnext(): No response from localhost in C:\test.php on line 2
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 09:00:01 2025 UTC |
At least it works as supposed on Linux with Net-SNMP and PHP-5.3.6... $ php -r 'print_r(snmpwalkoid("localhost", "public", ""));' | head Array ( [SNMPv2-MIB::sysDescr.0] => STRING: Linux james 2.6.37-2-amd64 #1 SMP Sun Feb 27 10:12:22 UTC 2011 x86_64 [SNMPv2-MIB::sysObjectID.0] => OID: NET-SNMP-MIB::netSnmpAgentOIDs.10 ...