lourite
asked on
PHP Fatal error: Call to undefined function snmpwalk()
Starting out playing with the PHPCLI and snmp functionality.
--Running php 5.0.4, phpinfo displays '--enable-ucd-snmp-hack' '.
--Downloaded net-snmp 5.3.1 rpm and upgraded via rpm -u as older version already existed on system.
Wrote short script to just test things out...
-------------------------- ---------- ---------- ------
#!/usr/bin/php
<?
$sysname = snmpwalk('hostname', 'community', 'system.sysName.0');
print '$sysname';
?>
-------------------------- ---------- ----------
On running script I get the above error.....kinda stuck...any ideas??
--Running php 5.0.4, phpinfo displays '--enable-ucd-snmp-hack' '.
--Downloaded net-snmp 5.3.1 rpm and upgraded via rpm -u as older version already existed on system.
Wrote short script to just test things out...
--------------------------
#!/usr/bin/php
<?
$sysname = snmpwalk('hostname', 'community', 'system.sysName.0');
print '$sysname';
?>
--------------------------
On running script I get the above error.....kinda stuck...any ideas??
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This issue seems to be specific to snmp, which is sadly not something I'm familiar with, sorry. :-/
ASKER
Ok now I am getting this error....
-----------------------
No log handling enabled - turning on stderr logging
Cannot find module (LM-SENSORS-MIB): At line 1 in (none)
$sysname
----------------------
What else do I need to do??
I am doubling the points sense this has turned into 2 questions...or should I post a new question??