Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Programming/Scripts

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 18th October 2007, 13:52
rjamesd rjamesd is offline
Member
 
Join Date: Aug 2007
Posts: 35
Thanks: 3
Thanked 4 Times in 3 Posts
Question phpmyadmin "Cannot load mysql extension. Please check your PHP configuration"

When I attempt to visit the phpmyadmin index page i.e.

http://localhost/phpmyadmin/index.php

I get: Cannot load mysql extension. Please check your PHP configuration.
error message

Now, I assume that 'mysql extension' and PHP MySQL package are actually the same thing, but different names.

Using synaptic debian package manager I can see that I have php5-mysql installed so I should not be getting the above error message.

I suspect that phpmyadmin has made an assumption about the path location of the PHP MySQL package so all I need to do is find how/where phpmyadmin looks for the PHP MySQL package.

Can you advise me where the phpmyadmin settings are stored?
Reply With Quote
Sponsored Links
  #2  
Old 19th October 2007, 13:39
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,747 Times in 2,578 Posts
Default

You can add the line
Code:
extension=mysql.so
to your php.ini (should be /etc/php5/apache2/php.ini or something like that) and restart Apache.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 23rd October 2007, 16:59
rjamesd rjamesd is offline
Member
 
Join Date: Aug 2007
Posts: 35
Thanks: 3
Thanked 4 Times in 3 Posts
Thumbs down Thanks BUT It doesn't work. Still get same error.

Quote:
Originally Posted by falko
You can add the line
Code:
extension=mysql.so
to your php.ini (should be /etc/php5/apache2/php.ini or something like that) and restart Apache.
Thanks BUT It doesn't work. Still get same error.

mysql.so is a file and your solution doesn't precede the mysql.so with a path for the file so it assumes that PHP will know where to look for this file, apart from the current working directory that the php.ini is in.

On my set up, doing a find from the root / directory, find . -name mysql.so
Gives:
./usr/lib/php5/20060613+lfs/mysql.so
./usr/lib/perl5/auto/DBD/mysql/mysql.so

Neither of these seem to apply to my setup because info.php tells me I'm running PHP Version 4.4.4-8+etch4 (i.e. not PHP5)
and the php.ini file is: /etc/php4/apache2/php.ini

As I have done in other posts - when or if I find a solution to my own problem I will post it here.
Reply With Quote
  #4  
Old 23rd October 2007, 17:04
rjamesd rjamesd is offline
Member
 
Join Date: Aug 2007
Posts: 35
Thanks: 3
Thanked 4 Times in 3 Posts
Thumbs down Thanks BUT It doesn't work. Still get same error.

Quote:
Originally Posted by falko
You can add the line
Code:
extension=mysql.so
to your php.ini (should be /etc/php5/apache2/php.ini or something like that) and restart Apache.
Thanks BUT It doesn't work. Still get same error.

mysql.so is a file and your solution doesn't precede the mysql.so with a path for the file so it assumes that PHP will know where to look for this file, apart from the current working directory that the php.ini is in.

On my set up, doing a find from the root / directory, find . -name mysql.so
Gives:
./usr/lib/php5/20060613+lfs/mysql.so
./usr/lib/perl5/auto/DBD/mysql/mysql.so

Neither of these seem to apply to my setup because info.php tells me I'm running PHP Version 4.4.4-8+etch4 (i.e. not PHP5)
and the php.ini file is: /etc/php4/apache2/php.ini

As I have done in other posts - when or if I find a solution to my own problem I will post it here.
Reply With Quote
  #5  
Old 23rd October 2007, 17:27
rjamesd rjamesd is offline
Member
 
Join Date: Aug 2007
Posts: 35
Thanks: 3
Thanked 4 Times in 3 Posts
 
Lightbulb Solution

The problem was that I did not have php4-mysql package installed.

I know this because I used synaptic package manager (type synaptic at the command line) which showed that php4-mysql was not installed.

I installed this and phpmyadmin works

I did not follow your advice falco - I did not need to edit the php.ini file.

But thanks anyway.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Freebsd 6.1 support misterm Installation/Configuration 10 9th April 2009 10:29
Slightly Confused (DNS & Server Help) JohnnyBGoode Installation/Configuration 26 14th August 2007 10:54
Apache2 Freezes celtic Server Operation 31 28th May 2007 18:18
Downgrade php5 to php4.4.2 llizards Installation/Configuration 4 14th March 2006 00:58


All times are GMT +2. The time now is 06:19.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.