473,383 Members | 1,868 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Call to undefined function snmpget()

I am using "PHP 5.2.4 (cli) (built: Nov 17 2009 16:22:15)" build, apache 2.
when i am executing the php script with snmpget() function it works fine, while when i ran it through web it gives "Call to undefined function snmpget()" error.
Mar 22 '10 #1
3 15338
Atli
5,058 Expert 4TB
Hey.

The server that is giving you that error most likely doesn't have the SNMP extension installed. To use the function you need to install the extension.

See the manual for installation instructions. If you are using a hosting service, you will have to ask your host to install this.
Mar 22 '10 #2
Hi Atli,
thanks for quick reply, in my machine we have installed using rpm, so i installed one rpm relevent to snmp and php, then also it gave same problem as before, it runs fine when php script is executed from terminal, but gives call to undefine function snmpget() when it is run from browser its web..

So what i belive that snmp package of php is running fine, but is it possible that the problem is between interface with apache and php, or like apache has not appropriate rights to call this function?

Thanks ones gain for your reply...
Mar 23 '10 #3
Hi,
My problem is resolved, i had build php using new source code and build using following parameters

./configure --enable-ucd-snmp-hack --with-openssl=/usr --with-snmp and my problem got solve, previously i was building only with

./configure --enable-ucd-snmp-hack --with-openssl=/usr

Thanks Atli for your quick response..
Mar 25 '10 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Krzysztof | last post by:
Hello, I noteced a weird problem with php snmpget. When I get two different consecutive queries from Cisco box (actualy, any box) and if the first returned value is not empty, but the second one...
1
by: Krzysztof | last post by:
No one could answer my question lately, so maybe today I will have some luck :-) Here we go again: I noteced a weird problem with php snmpget. When I get two different consecutive queries from...
3
by: WIWA | last post by:
I have recently installed pySNMP 3.3.2 and use Python 2.2.2. Thanks to Peter Hansen, I succeeded to install pySNMP properly. I'm not completely new to SNMP (I know the basics), but I'm new to...
9
by: Netocrat | last post by:
Any comments on the correctness of the statements 1, 2a, 2b, 3 and 4 in the code below? If they are correct, then the definition of an object as well as that of an lvalue is broken in C99 by the...
8
by: Cruella DeVille | last post by:
I'm writing a class to handle reading/writing from/to files like this (shortened) lass FileIO{ private $filename; private $mode; private $filePointer; private $dictionary; public function...
20
by: sam_cit | last post by:
Hi Everyone, I have the following code, int main() { int p = {10,20,30,40,50}; int *i = &p; printf("before : %p\n",(void*)i); printf("1 %d %d\n",*++i,*i++);
11
by: Felix Kater | last post by:
Hi, I can compile and run this code (see below) which twice calls the function f, first with too less, second with too much arguments. But is it legal and free of memory leaks and other...
9
by: CryptiqueGuy | last post by:
Consider the variadic function with the following prototype: int foo(int num,...); Here 'num' specifies the number of arguments, and assume that all the arguments that should be passed to this...
9
by: Yannick | last post by:
Hi everyone - I am not quite sure to understand what is really going on when a function defined in one translation unit calls a function defined in a different translation unit without knowing...
7
by: moon1 | last post by:
how will I change the code the 1st code according to the 2nd one? 1st code sub snmpGet(@) { # Assign arguments my ($deviceName)=$_; # Device name to read from my...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.