Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

PHP installation appears to be missing the MySQL extension

Discussion in 'EasyApache' started by OooLong, Aug 19, 2017.

  1. OooLong

    OooLong Well-Known Member

    Joined:
    Mar 16, 2011
    Messages:
    89
    Likes Received:
    0
    Trophy Points:
    56
    cPanel Access Level:
    Website Owner
    I'm getting this error to my site when using ea-php70 with suphp handlers. I checked other already made thread on this issue and there were no problem with suphp_configpath as it's not present in the public_html/.htaccess file. I'm not exactly sure how to tackle this issue. If I revert to php56 cgi handler then I no longer get this error but I want to get it to work with php70 as suphp. Any idea why it say that? Thanks in advance.
     
  2. OooLong

    OooLong Well-Known Member

    Joined:
    Mar 16, 2011
    Messages:
    89
    Likes Received:
    0
    Trophy Points:
    56
    cPanel Access Level:
    Website Owner
    Actually since i'm using php-fpm the handlers didn't matter. As long as I switch to php56 then I no longer get that error.
     
  3. OooLong

    OooLong Well-Known Member

    Joined:
    Mar 16, 2011
    Messages:
    89
    Likes Received:
    0
    Trophy Points:
    56
    cPanel Access Level:
    Website Owner
    I think I found the problem:

    [root@ade-423 public_html]# ls /opt/cpanel/ea-php70/root/usr/lib64/php/modules
    bcmath.so calendar.so ctype.so curl.so dom.so ftp.so gd.so imap.so json.so mbstring.so mcrypt.so mysqli.so mysqlnd.so opcache.so pdo_mysql.so pdo.so pdo_sqlite.so phar.so posix.so simplexml.so sockets.so sqlite3.so tokenizer.so wddx.so xmlreader.so xml.so xmlwriter.so xsl.so zip.so
    [root@ade-423 public_html]# ls /opt/cpanel/ea-php56/root/usr/lib64/php/modules
    bcmath.so ctype.so dom.so gd.so json.so mcrypt.so mysqlnd_mysql.so pdo_mysqlnd.so pdo_sqlite.so posix.so sockets.so tokenizer.so xmlreader.so xmlwriter.so
    calendar.so curl.so ftp.so imap.so mbstring.so mysqlnd_mysqli.so mysqlnd.so pdo.so phar.so simplexml.so sqlite3.so wddx.so xml.so xsl.so

    The php70 is missing these files in the modules mysqlnd_mysqli.so, mysqlnd_mysql.so, pdo_mysqlnd.so

    How do I go about properly installing these files to ea-php70? Thank you.
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,165
    Likes Received:
    1,371
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    You can install the missing extensions for PHP 7.0 with the following command:

    Code:
    yum install ea-php70-php-mysqlnd
    Here's the list of modules in the directory you referenced after installing the RPM with the above command:

    Code:
    #  ls /opt/cpanel/ea-php70/root/usr/lib64/php/modules|grep mysql
    mysqli.so
    mysqlnd.so
    pdo_mysql.so
    
    Thank you.
     
  5. OooLong

    OooLong Well-Known Member

    Joined:
    Mar 16, 2011
    Messages:
    89
    Likes Received:
    0
    Trophy Points:
    56
    cPanel Access Level:
    Website Owner
    Michael,

    I already have ea-php70-php-mysqlnd installed in Easyapache 4. These files are not on found in
    /opt/cpanel/ea-php70/root/usr/lib64/php/modules: mysqlnd_mysqli.so, mysqlnd_mysql.so, pdo_mysqlnd.so

    Any idea why?
     

    Attached Files:

    • 2.jpg
      2.jpg
      File size:
      49.4 KB
      Views:
      3
    #5 OooLong, Aug 21, 2017
    Last edited: Aug 21, 2017
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,165
    Likes Received:
    1,371
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Are you using updated versions of the RPMs? You can check this by running the following command:

    Code:
    yum update
    If so, try reinstalling the RPM with this command:

    Code:
    yum reinstall ea-php70-php-mysqlnd
    Thank you.
     
  7. OooLong

    OooLong Well-Known Member

    Joined:
    Mar 16, 2011
    Messages:
    89
    Likes Received:
    0
    Trophy Points:
    56
    cPanel Access Level:
    Website Owner
    Michael,

    I did what you said, yum update and then reinstall. Those files are still missing in php70, yet they are there in php55 and php56. Do you think just copying those files over to php70 make it work just the same? Thanks.
     
  8. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,165
    Likes Received:
    1,371
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Manually moving those files into place is not advised. Could you open a support ticket using the link in my signature so we can take a closer look?

    Thank you.
     
Loading...

Share This Page