ID:               38613
 Updated by:       [EMAIL PROTECTED]
 Reported By:      neil at fissure dot net
-Status:           Open
+Status:           Feedback
 Bug Type:         SNMP related
 Operating System: CentOS release 4.3
 PHP Version:      5.1.5
 New Comment:

Why do you think it's a PHP issue?



Previous Comments:
------------------------------------------------------------------------

[2006-08-27 02:26:12] neil at fissure dot net

Description:
------------
Similar to bug:
#32680  PHP_MSHUTDOWN PHP_MINIT

PHP gives errors when used as an Apache Module, but the 
same source code works via PHP CLI

Reproduce code:
---------------
error_reporting(E_ALL);

$host = "xxx";
$community = "xxx";

$syscontact = snmpget($host, $community, "system.sysName.0");

PRINT "<BR>$syscontact\n";

Expected result:
----------------
<BR>STRING: 7200

Actual result:
--------------
Warning: snmpget() [function.snmpget]: Could not open 
snmp connection: Unknown host in /usr/local/apache/
htdocs/xxx/snmpwalk.php3 on line 9

I'm running:
PHP Version 5.1.6
'./configure' '--with-mysql' '--with-mysqli' '--enable-
mbstring' '--with-zlib-dir=/usr' '--with-curl' '--with-
snmp' '--with-apache=../apache_1.3.37' '--enable-ucd-
snmp-hack'

('--enable-ucd-snmp-hack' was added in troubleshooting)

Using:
Name   : net-snmp
Arch   : i386
Version: 5.1.2
Release: 11.EL4.6

Once, but only once stracing the httpd process, I saw:
write(2, "No support for requested transpo"..., 48) = 48
which I believe came from net-snmp


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=38613&edit=1

Reply via email to