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.

VPS upgrade php/mysql 'libmysqlclient_14' not found'

Discussion in 'General Discussion' started by jamesbond, Aug 20, 2006.

  1. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    On a CentOS 4.3 VPS (RELEASE 119) I upgraded PHP from 4.4.4 to 5.1.5, and MySQL from 4.1 to 5.0.24.
    Everything works fine, but I noticed /scripts/mysqlup gives this error now:

    MySQL Setup Script Version 7.0
    Loaded cPPkgs::MySQL ok!
    This is the cPPkgs::MySQL 5.0.24 installer for Linux.
    MySQL 5.0.24 is up to date
    /usr/local/apache/libexec/libphp4.so: /usr/lib/libmysqlclient.so.14: version `libmysqlclient_14' not found (required by /usr/local/apache/libexec/libphp4.so)

    I recompiced apache & php twice after upgrading to MySQL 5, but somehow there is a link to /usr/local/apache/libexec/libphp4.so somewhere, that doesn't get updated to /usr/local/apache/libexec/libphp5.so

    Has anyone else come across this?
     
    #1 jamesbond, Aug 20, 2006
    Last edited: Aug 20, 2006
  2. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Well, I'm going to answer this myself :)

    I removed /usr/local/apache/libexec/libphp4.so, since it is not needed anymore after upgrading to PHP 5. This took care of the libmysqlclient14 error:

    I guess this function in /scripts/mysqlup is causing the problem:

    Code:
    sub checkphplinkage {
        my ( @LIBS, @LIBS4, @LIBS5, %REQS );
    
        if ( -e '/usr/local/apache/libexec/libphp4.so' ) {
            @LIBS4 = split( /\n/, `ldd /usr/local/apache/libexec/libphp4.so` );
        }
        if ( -e '/usr/local/apache/libexec/libphp5.so' ) {
            @LIBS5 = split( /\n/, `ldd /usr/local/apache/libexec/libphp5.so` );
        }
        @LIBS = grep( /libmysqlclient/,  @LIBS4, @LIBS5 );
        @LIBS = grep( /not\s+found/, @LIBS4, @LIBS5 );
        foreach my $lib (@LIBS) {
            chomp $lib;
            if ( $lib =~ /(libmysqlclient.so.\S+)/ ) {
                $REQS{ $1 } = 1;
            }
        }
    
     
  3. touma

    touma Member

    Joined:
    Apr 13, 2004
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    São Paulo - Brasil
    I had to remove /usr/local/apache/libexec/libphp4.so and recompile apache. This created libphp5.so in /usr/local/apache/libexec/.

    After that I had to comment line
    LoadModule php4_module libexec/libphp4.so

    and uncomment/add line
    LoadModule php5_module libexec/libphp5.so

    Thanks for the tip!
     
  4. equens

    equens Well-Known Member

    Joined:
    Feb 8, 2002
    Messages:
    270
    Likes Received:
    0
    Trophy Points:
    16
    I have the same problem, do I need to uncomment the LoadModule php5_module libexec/libphp5.so?

    Why cannot Cpanel does it?
     
  5. erick_paper

    erick_paper Well-Known Member

    Joined:
    Apr 19, 2005
    Messages:
    245
    Likes Received:
    0
    Trophy Points:
    16
    Same problem. Could you people please not assume that everyone who comes here knows what "apache recompile" means, and please include the steps for doing this? I am not sure why PHP 5.2 is not included within WHM, it works very well.

    Please advise how I can move forward. How should I install PHP 5.2 and MySQL 5.0.27 and get Apache to restart again? My entire website is down. Thanks!!
     
  6. jorj1

    jorj1 Member

    Joined:
    Nov 21, 2004
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    same problem - bug to fix in findmysql version

    Since the last post there were some changes in the scripts and into the apache configuration file which does not fit under certain circumstances.

    Specifically, mysqlup script uses findmysqlversion now to get the mysql version. however, this fails because it looks into httpd.conf for lines containing:

    LoadModule php5_module modules/libphp5.so

    The problem is that the line above was moved into /usr/local/apache/conf/php.conf and so findmysqlversion will fail when scanning httpd.conf and will try to get the version by running /usr/local/bin/php which will also fail if the library above is not found.

    my solution was to replace httpd.conf with php.conf into findphpversion and update the apache after


    my $sl = cPScript::SafeFile::safeopen( \*APC, '/usr/local/apache/conf/php.conf' );

    hope this helps
     
Loading...

Share This Page