From:             lee dot duncan at intel dot com
Operating system: SUSE, Kernel 2.6.8-24.21-smp
PHP version:      5.1.4
PHP Bug Type:     Feature/Change Request
Bug description:  The SNMP extension does not support setting multiple OIDs

Description:
------------
In order to add an entry to many SNMP tables, you need to 
be able to set multiple OIDs (values) at the same time. The 
net-snmp "snmpset" command allows this, as do the 
libnetsnmp APIs, but the SNMP extension to PHP does not 
support this. 
 
I added a new function to ext/snmp.c to support setting 
multiple values at once, and I'd like to see it added to 
the PHP SNMP extension for all to use. 

Reproduce code:
---------------
Just try to set multiple SNMP OIDs (object IDs) with the current API,
which is:

proto int snmp2_set(string host, string community, string object_id,
string type, mixed value [, int timeout [, int retries]])

I added:

proto int snmp2_set_arr(string host, string community, array oids, array
types, array values [, int timeout [, int retries]])

This way, no current programs break and new programs can use this
functionality.

Expected result:
----------------
I'd like to be able to manage things like Marvell switches, 
which only allow adding a Table entry (e.g. for a new VLAN) 
if you can set multiple values (OIDs) at the same time. 

Actual result:
--------------
Right now I can't do this without hacking the PHP SNMP 
extension. 

-- 
Edit bug report at http://bugs.php.net/?id=37865&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=37865&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=37865&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=37865&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=37865&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=37865&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=37865&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=37865&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=37865&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=37865&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=37865&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=37865&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=37865&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=37865&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=37865&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=37865&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=37865&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=37865&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=37865&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=37865&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=37865&r=mysqlcfg

Reply via email to