Edit report at http://bugs.php.net/bug.php?id=38516&edit=1
ID: 38516
User updated by: larryjadams at comcast dot net
Reported by: larryjadams at comcast dot net
Summary: functions snmpgetnext and snmp2_getnext do not work
-Status: Open
+Status: Closed
Type: Feature/Change Request
Package: SNMP related
Operating System: Win32
PHP Version: 5.1.5
Block user comment: N
Private report: N
New Comment:
Not a problem.
Previous Comments:
------------------------------------------------------------------------
[2011-03-20 15:24:22] ch at lathspell dot de
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
...
------------------------------------------------------------------------
[2006-08-23 17:33:07] larryjadams at comcast dot net
Sorry Tony, the OID should be optional in this call. If it is found to
be blank, the function should behave like net-snmp's getnext when it is
called without an OID, which is to return the first OID from the entire
tree, typically sysDescr.
Today it is not optional and fails when left to a blank string.
------------------------------------------------------------------------
[2006-08-23 17:05:27] [email protected]
What fix are you talking about?
Please explain first what do you think is wrong and how to reproduce it.
------------------------------------------------------------------------
[2006-08-23 15:39:28] larryjadams at comcast dot net
Tony,
How bout I send you a fix. I can do that much np. I could also send
you the fix to build net-snmp for windows rather than ucd-snmp if you
like.
------------------------------------------------------------------------
[2006-08-23 15:18:01] larryjadams at comcast dot net
You are right, daddy needs a new pair of glasses. However, if you set
the OID string to "", it still fails, while, if you run the following
command from the command line it will still work:
snmpgetnext -c public -v 1 localhost
The php_snmp requires the OID to be something other than a blank string.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/bug.php?id=38516
--
Edit this bug report at http://bugs.php.net/bug.php?id=38516&edit=1