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!

Can't make pdo_dblib to work

Discussion in 'EasyApache' started by jmaurin, Apr 27, 2018.

  1. jmaurin

    jmaurin Member

    Joined:
    Aug 6, 2014
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi.

    I'm trying to compile and enable pdo_dblib, but isn't loading. I've downlaoded source code of PHP 7.1.16 (which is the same version that I'm using in my cpanel), entered dir 'ext/pdo_dblib' and done these commands to compile:
    /opt/cpanel/ea-php71/root/usr/bin/phpize
    ./configure --with-php-config=/opt/cpanel/ea-php71/root/usr/bin/php-config --with-pdo-dblib=/opt/cpanel/freetds --with-libdir=/lib64
    make

    All runs fine. After 'make install', module are installed in correct location (/opt/cpanel/ea-php71/root/usr/lib64/php/modules/pdo_dblib.so). I also have enabled this module in correct php.ini, but when I try to load any script (including phpinfo()), I can't see this module.....module isn't loaded! And I can't see any errors, nothing.

    Also tryied to manuallo load module with:
    /opt/cpanel/ea-php71/root/usr/bin/php -dextension=/opt/cpanel/ea-php71/root/usr/lib64/php/modules/pdo_dblib.so myphpfile.php

    But still not working, module looks not loaded and no errors. My question is: there is any block or anything else that I need to do?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,903
    Likes Received:
    1,814
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. jmaurin

    jmaurin Member

    Joined:
    Aug 6, 2014
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Actually, this isn't the same thing. PDO_ODBC is enabled by EA4, this is not the problem. What I need to enable is PDO_DBLIB. If you get the source of PHP 7.1.16 (or any other) you will see this extension directory. I can compile fine, just load that isn't working.
     
  4. jmaurin

    jmaurin Member

    Joined:
    Aug 6, 2014
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Solved!
    Tha problem is that dblig conflicts with odb extension, but without any error!
    So you must disable ODBC extensons to load DBLIB. Now it's working fine. But would be even better if Cpanel could create an packet for dblib extensions, like other extensions, since it's an official extension from php source.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,903
    Likes Received:
    1,814
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello @jmaurin,

    I'm glad to see you were able to solve the issue. Do you mind sharing the specific steps you took to reproduce the error, and then to solve it, so we can have a better idea of what's happening?

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice