I got new server and installed phpMyAdmin. But whenever I visit the phpmyadmin url it says:
Cannot load mysql extension. Please check your PHP configuration
How do I fix this problem under CentOS / RHEL / Fedora Linux Apache web server?
You need to install php-mysql which is a module for PHP applications that use MySQL databases. You may also need to install the following:
- php-mysql : Module for PHP applications that use MySQL databases
- php-gd : A module for PHP applications for using the gd graphics library
- php-mbstring : A module for PHP applications which need multi-byte string handling
- php-mcrypt : Standard PHP module provides mcrypt library support
Type the following command to fix your issue:
# yum -y install php-mysql
# service httpd graceful
OR
# apachectl -k graceful
No need to edit /etc/php.ini as php-mysql package comes pre configured with /etc/php.d/mysql.ini file:
# cat /etc/php.d/mysql.ini
Sample outputs:
; Enable mysql extension module extension=mysql.so
Optional Modules
To install other modules type:
# yum -y install php-mbstring php-mcrypt php-gd
# service httpd graceful
Featured Articles:
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- My 10 UNIX Command Line Mistakes
- Linux: 20 Iptables Examples For New SysAdmins

- 25 PHP Security Best Practices For Sys Admins
- The Novice Guide To Buying A Linux Laptop
- 10 Greatest Open Source Software Of 2009
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- Top 20 OpenSSH Server Best Security Practices
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Linux Video Editor Software
Facebook it - Tweet it - Print it -



{ 2 comments… read them below or add one }
Thank you, Works fine for me.
No package php-mcrypt available