LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   phpMyAdmin - Cannot load mySQL extension (https://www.linuxquestions.org/questions/linux-software-2/phpmyadmin-cannot-load-mysql-extension-589556/)

blizunt7 10-05-2007 12:24 AM

phpMyAdmin - Cannot load mySQL extension
 
Hey all,
Having one long night trying to get phpMyAdmin working on my RHEL4 box. Got mysql install properly:
Code:

$rpm -qa | grep -i mysql
MySQL-devel-community-5.0.45-0.rhel4
MySQL-shared-community-5.0.45-0.rhel4
MySQL-client-community-5.0.45-0.rhel4
MySQL-server-community-5.0.45-0.rhel4

and have php installed:
Code:

$rpm -qa | grep -i php
php-ldap-4.3.9-3.15
php-4.3.9-3.15
php-pear-4.3.9-3.15

and have apache up and working.

When i try to open up phpMyAdmin i get:
Code:

Cannot load mysql extension. Please check your PHP configuration.
I have read many threads and from what I see I need to install php-mysql.
I downloaded the RPM and trying to install, and get the following:
Code:

$rpm -ivh php-mysql-4.3.9-3.22.9.i386.rpm
error: Failed dependencies:
        libmysqlclient.so.14 is needed by php-mysql-4.3.9-3.22.9.i386
        libmysqlclient.so.14(libmysqlclient_14) is needed by php-mysql-4.3.9-3.22.9.i386
        php = 4.3.9-3.22.9 is needed by php-mysql-4.3.9-3.22.9.i386
    Suggested resolutions:
        mysql-4.1.20-1.RHEL4.1.i386.rpm

As well i tried the php-mysql-4.3.9-3.15.i386.rpm package, maybe version needed to be the same as PHP. Guess not.

I would much prefer to keep mysql 5 and not have to backtrack.

my my.cnf as follows:
Code:

$cat /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
   
[mysql.server]
user=mysql
#basedir=/var/lib

[mysqld_safe]
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid


Any help would be awsome!
Thanks so much.

blizunt7 10-05-2007 12:37 AM

another note:

phpinfo reports:

Code:

--with-mysql=shared,/usr' '--with-pgsql=shared' '-
and
Code:

$which mysql
/usr/bin/mysql


blizunt7 10-05-2007 02:59 PM

I did finally get php-mysql installed,
restarted mysql, and apache

But still getting
Code:

Cannot load mysql extension. Please check your PHP configuration. - Documentation
I have tried so many things. Not sure what to do.

Anyone have a suggestion would be awsome!

kishore2k4 10-09-2007 09:32 AM

I am having the exact same problem but with php5. Any suggestions?

Update:

Problem solved by installing php-mysql of the same version as my php installation


All times are GMT -5. The time now is 11:13 PM.