Daveyboy Posted June 27, 2007 Share Posted June 27, 2007 I installed cacti and received this ( http://ubuntuforums.org/attachment.php?attachmentid=36581&d=1182913866 ) when installing, now I am getting this error when I run the poller.php; Fatal error: Call to undefined function mysql_pconnect() in /usr/share/php/adodb/drivers/adodb-mysql.inc.php on line 372 I edited my php.ini to this; ; UNIX: "/path1:/path2" include_path = ".:/usr/share/php:/usr/share/php/adodb/" but no luck, I am using Ubuntu server, Linux version 2.6.15-23-386 (buildd@rothera) (gcc version 4.0.3 (Ubuntu 4.0.3-1ubuntu5)) #1 PREEMPT Tue May 23 13:49:40 UTC 2006, please advise, thanks Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/ Share on other sites More sharing options...
trq Posted June 27, 2007 Share Posted June 27, 2007 Try using mysql_connect instead of mysql_pconnect Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-284420 Share on other sites More sharing options...
Daveyboy Posted June 28, 2007 Author Share Posted June 28, 2007 I do not want to change the php scripts, as this is the cacti program giving this error. I merely want to change the php.ini or any other config to let the scripts run through. Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-284453 Share on other sites More sharing options...
trq Posted June 28, 2007 Share Posted June 28, 2007 Well, changing the include_path won't help. It looks like php was not compiled with mysql support. Make a test page... <?php phpinfo(); ?> Do you have the mysql extension? Take a look at this sticky. Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-284759 Share on other sites More sharing options...
Daveyboy Posted June 29, 2007 Author Share Posted June 29, 2007 Although that sticky is windows based, I get the general concept, I need the include path to point to the php5 directory. Here is what I did below, but still getting the same "Fatal error: Call to undefined function mysql_pconnect() in /usr/share/php/adodb/drivers/adodb-mysql.inc.php on line 372" 1 .added this to my /etc/php5/apache2/php.ini based on the output of 'whereis php5' ; UNIX: "/path1:/path2" include_path = ".:/usr/share/php/:/usr/bin/php5:/etc/php5:/usr/lib/php5:/usr/share/php5:/usr/share/man/man1/php5.1.gz" 2. When i installed the LAMP stack i install this pack apt-get install apache2 php5 libapache2-mod-php5 mysql-server mysql-client php5-mysql I thought the php5-mysql is the mysql extension support of php5? 3. Anyway, here is the mysql portion of of my php test page(see attach) [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-286154 Share on other sites More sharing options...
trq Posted July 1, 2007 Share Posted July 1, 2007 The include_path has nothing to do with extensions. It is merely the search path for php to search when looking for included files. As far as I can tell from the image you have provided, you have full mysql support, and persistent connections are enabled. I would maybe try adding mysql to your dynamically loaded extensions within the php.ini. Seems an odd way fro a distro to set things up, but it may be the case. Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-287068 Share on other sites More sharing options...
neylitalo Posted July 13, 2007 Share Posted July 13, 2007 On Unix-based platforms, I don't believe php.ini has anything to do with the loaded modules. And, to me, the fact that there is a section for mysql seems to indicate that the module has been loaded. Unfortunately, that doesn't help the situation any. :/ Daveyboy: Do any MySQL related functions work? Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-297022 Share on other sites More sharing options...
Daveyboy Posted July 17, 2007 Author Share Posted July 17, 2007 apparently the php had to be compiled from source, see this new thread http://www.phpfreaks.com/forums/index.php/topic,150015.0.html Quote Link to comment https://forums.phpfreaks.com/topic/57485-solved-phpini-and-apache2conf/#findComment-299966 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.