ID:               32613
 User updated by:  ric at arizona dot edu
 Reported By:      ric at arizona dot edu
-Status:           Bogus
+Status:           Open
 Bug Type:         SNMP related
 Operating System: Solaris 8
 PHP Version:      4.3.11
 New Comment:

After much reading on this, I found the problem to be the
snmp_shutdown() call added in php 4.3.11.  The fix for the
errors this is twofold
a) modify php to include
   netsnmp_ds_set_boolean(NETSNMP_DS_LIBRARY_ID,
    NETSNMP_DS_LIB_DONT_PERSIST_STATE, 1);
   in php startup, so the newly added snmp_shutdown call 
   won't try to write data.
-AND-
b) update to net-snmp-5.2.1 which recognizes the above
   call.
---


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

[2005-04-07 01:51:42] ric at arizona dot edu

I disagree with the "its net-snmp's fault" response.  How can  it be
net-snmp's problem when php 4.3.10 built with the exact same net-snmp
within a couple of hours of building 4.3.11 does not exhibit the
problem of trying to write to /var/net-snmp???

Isn't it more likely that there was some change php's use of net-snmp
between 4.3.10 and 4.3.11 that triggered this change in behavior?

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

[2005-04-07 00:26:03] [EMAIL PROTECTED]

This is not any PHP bug to fix, complain to the net-snmp people about
this. There might be some configuration options in the snmp.conf &
friends to control this behaviour..


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

[2005-04-06 23:50:41] ric at arizona dot edu

Description:
------------
Build environment is Solaris 8 with net-snmp5.1.

I built php 4.3.11 with
 ./configure --with-mysql=/usr/local  \
     --with-openssl=/usr/local/ssl --with-ldap \
     --with-apxs=/private/apache/bin/apxs --with-xml --with-pspell \
     --with-snmp --with-zlib
    make

The build completed normally, but when I then run
 $ /dfs/src/solaris/php-4.3.11/sapi/cli/php--version
I get
 PHP 4.3.11 (cli) (built: Apr  6 2005 11:12:09)
 Copyright (c) 1997-2004 The PHP Group
 Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
 Cannot rename /var/net-snmp/snmpapp.conf to
/var/net-snmp/snmpapp.0.conf
 Cannot unlink /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf

On the same computer with the same environment, I built
php 4.3.10, and it produces no such errors, viz:
 $ /dfs/src/solaris/php-4.3.10/sapi/cli/php --version
 PHP 4.3.10 (cli) (built: Apr  6 2005 14:30:39)
 Copyright (c) 1997-2004 The PHP Group
 Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies

4.3.11 appears to need write access to /var/snmp to 
be able to rename files and read/write access to snmpapp.conf.   Short
of making /var/snmp world write,
and snmpapp.conf world write is there a way to restore
the 4.3.10 behvior which doesn't even require the
existance of /var/net-snmp?

Thanks
Ric Anderson ([EMAIL PROTECTED])

Reproduce code:
---------------
Configure and build 4.3.11 --with-snmp, and then try
to run
 sapi/cli/php --version
as a mortal (non-root) user.

Expected result:
----------------
I expect to see the version info e.g.
 PHP 4.3.11 (cli) (built: Apr  6 2005 11:12:09)
 Copyright (c) 1997-2004 The PHP Group
 Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies

Actual result:
--------------
 PHP 4.3.11 (cli) (built: Apr  6 2005 11:12:09)
 Copyright (c) 1997-2004 The PHP Group
 Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
 Cannot rename /var/net-snmp/snmpapp.conf to
/var/net-snmp/snmpapp.0.conf
 Cannot unlink /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf
 read_config_store open failure on /var/net-snmp/snmpapp.conf


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


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

Reply via email to