Hello I need to install magento on my server and for this it requires pdo_mysql

I am trying to install pdo_mysql via whm option "Easy Apache"
I tick the pdo_mysql option
but after apache rebuilding process the phpinfo not showing pdo_mysql

Do I need to enable it some where
I also made the following changes in /usr/local/lib/php.ini

extension=pdo.so
extension=pdo_mysql

but its not working
Any help would be appreciated

I am on Centos 6 with whm/cpanel installed

Dani AI

Generated

A concise diagnostic and remedial checklist for (building on 's suggestion to look for the compiled module).

Create a tiny PHP info page and load it in the browser to see exactly which PHP SAPI and php.ini Apache is using:

<?php
phpinfo();
?>

In that output note three things: the "Loaded Configuration File" (the php.ini Apache actually reads), the "PDO" section (it will list PDO drivers if the driver is present), and "extension_dir" / "Additional .ini files parsed" (where shared modules live or extra INI files are loaded).

From the shell, compare the CLI SAPI to Apache's SAPI and inspect available modules:

php -m
php -i | egrep "Loaded Configuration File|extension_dir|PDO"

If the CLI shows the PDO MySQL driver but the web phpinfo does not, the global php.ini was edited while Apache is using a different php.ini (or a per-site php.ini is overriding it). If neither shows the mysql PDO driver, check the extension_dir for a pdo_mysql shared object; if no such file exists, EasyApache did not build the driver.

Practical fixes and checks:

  • Re-run WHM -> EasyApache and ensure PDO and the PDO MySQL driver are selected for the exact PHP version in use; rebuild.
  • If the .so exists but is not loaded, ensure the php.ini that phpinfo reported loads it (use the .so filename) and that the PDO core is loaded before the driver. Avoid mixing system yum PHP packages with cPanel/EasyApache builds.
  • Check Apache error log for module-load errors (for example, /usr/local/apache/logs/error_log) and restart Apache via WHM or the appropriate cPanel script after changes.

If EasyApache reports a successful build but the module still cannot be found, the build log or Apache error log will show why the driver did not load.

If you can execute a shell, search the library:

find / -name *pdo*so 2>/dev/null

the 2>/dev/null segment will suppress the errors (usually due to permessions), you can remove it if you want to get all the output. After you save the config file remember to reload the server.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.