Bug #70382 [Opn->Fbk]: snmp2_real_walk claims "No response"
| From: | lytboris@php.net | Date: | Mon, 06 Jun 2016 07:48:40 +0000 |
| Subject: | Bug #70382 [Opn->Fbk]: snmp2_real_walk claims "No response" | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-201470@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=70382&edit=1
ID: 70382
Updated by: lytboris@php.net
Reported by: php at t-b-o-h dot net
Summary: snmp2_real_walk claims "No response"
-Status: Open
+Status: Feedback
Type: Bug
Package: SNMP related
Operating System: CentOS 6.3/Windows 7
PHP Version: 5.6.12
Block user comment: N
Private report: N
Previous Comments:
------------------------------------------------------------------------
[2016-06-06 07:12:17] lytboris@php.net
Well, using snmpwalk for a proof of a failure is not a way to go - use snmpbulkwalk for that or tune
your SNMP session (yep, use SNMP class) to query less OIDs in single packet. I suspect that remote
box can not handle too long packets effectively or your have some network issue at this point
resulting in packet loss.
------------------------------------------------------------------------
[2015-08-28 13:50:42] php at t-b-o-h dot net
Description:
------------
We are using an F5 BIGIP load balancer, and trying to monitor it. Running the test script results in
"PHP Warning: snmp2_real_walk(): No response from HOSTHERE in
/home/tuc/Desktop/snmp2_real_walk.php on line 2" on CentOS and Windows 7, versions 5.3.3
through 5.6.12 . However :
[tuc@monitoring-01.sf ~]$ time snmpwalk -v2c -c PASSWORD HOST .1.3.6.1.4.1.3375.2.2.10.2.3.1.1|wc
-l
48
real 0m0.104s
user 0m0.037s
sys 0m0.006s
In every case I look a tcpdump returns well before the script bombs.
The data returned (48 lines) includes some really long OIDS... :
SNMPv2-SMI::enterprises.3375.2.2.10.2.3.1.1.41.47.67.111.109.109.111.110.47.97.100.101.110.103.105.110.101.45.112.114.111.100.116.101.115.116.95.112.117.98.108.105.99.45.105.112.49.56.49.46.56.48
= STRING: "/Common/service1"
SNMPv2-SMI::enterprises.3375.2.2.10.2.3.1.1.42.47.67.111.109.109.111.110.47.97.100.101.110.103.105.110.101.45.112.114.111.100.116.101.115.116.95.112.117.98.108.105.99.45.105.112.49.56.49.46.52.52.51
= STRING: "/Common/service2"
Test script:
---------------
<?php
print_r(snmp2_real_walk("HOSTHERE:161", "PASSWORDHERE",
".1.3.6.1.4.1.3375.2.2.10.2.3.1.1"));
?>
Expected result:
----------------
48 line array of OIDs and strings such as above
Actual result:
--------------
"PHP Warning: snmp2_real_walk(): No response from HOSTHERE in
/home/tuc/Desktop/snmp2_real_walk.php on line 2"
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=70382&edit=1