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.

Bug Report PECL Related

Discussion in 'General Discussion' started by morefood2001, Dec 28, 2010.

  1. morefood2001

    morefood2001 Active Member

    Joined:
    Mar 18, 2008
    Messages:
    28
    Likes Received:
    0
    Trophy Points:
    1
    This may be a PECL bug, but I've decided to post it here to verify. Today I was requested to install the xdebug pecl extension to a CPanel server.

    Everything went well with the WHM PECL installer but once it was done, there were thousands of errors in the error logs that looked like the following:
    [28-Dec-2010 13:00:45] PHP Warning: Xdebug MUST be loaded as a Zend extension in Unknown on line 0

    This is because in PHP.ini, the extension was placed as follows:
    extension="xdebug.so"

    It really should be:
    zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so"


    Is this a CPanel related bug or a PECL related bug?

    Thanks,
    Phil
     
  2. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    What is your PHP and PEAR/PECL version? The following command can be used to obtain this information:
    Code:
    /usr/local/bin/pear version
    I am curious if the same or similar result occurs when using PECL directly via command-line (CLI). Please try using PECL via root SSH access to install the desired extension. The following documentation from PHP details command-line usage of PECL: PHP: Compiling shared PECL extensions with the pecl command - Manual
    Example:
    Code:
    # /usr/local/bin/pecl install xdebug
    When I tested an install via command-line, I found that the following php.ini entry was added (per output from grep):
    Code:
    # grep -i xdebug /usr/local/lib/php.ini
    extension="xdebug.so"
    To compare information, here is the PHP and PEAR/PECL version detail from my test system:
    Code:
    # /usr/local/bin/pear version | head -n3
    PEAR Version: 1.9.1
    PHP Version: 5.2.15
    Zend Engine Version: 2.2.0
    The result leads me to believe that the issue may stem from PHP PECL or the packaged extension. As a next step I would want to determine if PHP PECL can be triggered to use "zend_extension=" instead of "extension=" when updating the PHP configuration (php.ini) file.

    I recommend referring to the xdebug web site for official installation instructions: Xdebug: Documentation

    The Xdebug install documentation includes instruction to ignore certain prompts when installing via PECL; however, I did not see any prompts during my testing, leading me to believe it might be a default action.
    As an additional resource, I would also search the official bug tracker web site for xdebug in case others may have reported similar difficulty: My View - MantisBT - Xdebug
     
  3. morefood2001

    morefood2001 Active Member

    Joined:
    Mar 18, 2008
    Messages:
    28
    Likes Received:
    0
    Trophy Points:
    1
    First, thank you for your reply. I'm sorry that I haven't replied quicker.

    Here is the first output:

    root@bit [~]# /usr/local/bin/pear version
    PEAR Version: 1.9.1
    PHP Version: 5.3.4
    Zend Engine Version: 2.3.0
    Running on: Linux bit.matthouse.us 2.6.18-194.26.1.el5 #1 SMP Tue Nov 9 12:54:20 EST 2010 x86_64

    This is slightly different from your system.


    Actually, initially I installed the extension using the pear cli since I didn't realize CPanel had the ability to do it. I uninstalled it via the cli and proceeded to install it via CPanel.

    The same problem did occur through the initial (incorrect) installation through the cli, which leads me to believe it is a bug with pear / xdebug and not a bug related to CPanel.

    When I grep php.ini, the same exact thing happens regardless of where I install the pear module from (cli or cpanel).

    Finally, I read the same thing from the xdebug documentation, and that helped me to solve the problem. I just did something slightly differently by moving xdebug.so to the extensions directory in hopes of not having to specify a full path.

    I see a similar problem so I've posted to 0000648: Xdebug will not install - MantisBT and hopefully their developers will realize what the issue is and fix it.

    Once again, thanks for your time!
     
Loading...

Share This Page