MySQL 5.5, PHP And Other Tools Still Use 5.0 Client Drivers

Home » CentOS » MySQL 5.5, PHP And Other Tools Still Use 5.0 Client Drivers
CentOS 8 Comments

I upgraded a web server from CentOS 5.9 to 5.10. The instructions also indicate that MySQL 5.0 is no longer supported so I followed the instructions to upgrade to 5.5. Everything seems to be working so I
tried to remove MySQL 5.0 and MySQL 5.1. It seems there are still dependencies on MySQL 5.0:

[root@w3 ~]# rpm -e mysql51-mysql-libs-5.1.70-1.el5 mysql-server-5.0.95-5.el5_9 mysql51-build-1-9.el5 mysql51-mysql-5.1.70-1.el5 mysql51-mysql-server-5.1.70-1.el5 mysql51-mysql-test-5.1.70-1.el5 mysql-devel-5.0.95-5.el5_9 mysql-5.0.95-5.el5_9 mysql-test-5.0.95-5.el5_9 mysql51-runtime-1-9.el5 mysql51-1-9.el5 mysql51-mysql-bench-5.1.70-1.el5 mysql51-mysql-libs-5.1.70-1.el5 mysql51-build-1-9.el5 mysql51-mysql-5.1.70-1.el5 mysql51-mysql-server-5.1.70-1.el5 mysql51-mysql-test-5.1.70-1.el5 mysql51-runtime-1-9.el5 mysql51-1-9.el5 mysql51-mysql-bench-5.1.70-1.el5
error: Failed dependencies:
libmysqlclient.so.15 is needed by (installed) perl-DBD-MySQL-3.0007-2.el5.i386
libmysqlclient.so.15 is needed by (installed) mod_auth_mysql-3.0.0-3.2.el5_3.i386
libmysqlclient.so.15 is needed by (installed) mysql-connector-odbc-3.51.26r1127-2.el5.i386
libmysqlclient.so.15 is needed by (installed) cyrus-sasl-sql-2.1.22-7.el5_8.1.i386
libmysqlclient.so.15 is needed by (installed) dovecot-1.0.7-8.el5_9.1.i386
libmysqlclient.so.15 is needed by (installed) php53-mysql-5.3.3-21.el5.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) perl-DBD-MySQL-3.0007-2.el5.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) mod_auth_mysql-3.0.0-3.2.el5_3.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) mysql-connector-odbc-3.51.26r1127-2.el5.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) cyrus-sasl-sql-2.1.22-7.el5_8.1.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) dovecot-1.0.7-8.el5_9.1.i386
libmysqlclient.so.15(libmysqlclient_15) is needed by (installed) php53-mysql-5.3.3-21.el5.i386
libmysqlclient_r.so.15 is needed by (installed) mysql-connector-odbc-3.51.26r1127-2.el5.i386
libmysqlclient_r.so.15 is needed by (installed) MySQL-python-1.2.3-0.1.c1.el5.i386
libmysqlclient_r.so.15(libmysqlclient_15) is needed by (installed) mysql-connector-odbc-3.51.26r1127-2.el5.i386
libmysqlclient_r.so.15(libmysqlclient_15) is needed by (installed) MySQL-python-1.2.3-0.1.c1.el5.i386
mysql = 5.0.95-5.el5_9 is needed by (installed) mysql-bench-5.0.95-5.el5_9.i386
[root@w3 ~]# find /usr/lib -name libmysqlclient.so.15 -ls
721332 0 lrwxrwxrwx 1 root root 24 Jan 23 2013 /usr/lib/mysql/libmysqlclient.so.15 -> libmysqlclient.so.15.0.0
[root@w3 ~]# find /usr/lib -name libmysqlclient.so.15.0.0 -ls
721556 1424 -rwxr-xr-x 1 root root 1452764 Jan 22 2013 /usr/lib/mysql/libmysqlclient.so.15.0.0
[root@w3 ~]# rpm -qf /usr/lib/mysql/libmysqlclient.so.15.0.0
mysql-5.0.95-5.el5_9
[root@w3 ~]#

I started up httpd, mysql, etc, and used lsof to see which library was in use:
[root@w3 csm-vhosts]# lsof -p 4552 | grep mysql httpd 4552 apache mem REG 253,1 43032 593822 /usr/lib/php/modules/mysql.so httpd 4552 apache mem REG 253,1 113324 593824 /usr/lib/php/modules/mysqli.so httpd 4552 apache mem REG 253,1 24460 593835 /usr/lib/php/modules/pdo_mysql.so httpd 4552 apache mem REG 253,1 1452764 721556 /usr/lib/mysql/libmysqlclient.so.15.0.0
[root@w3 csm-vhosts]#

As I understand it, there is no longer any support for mysql-5.0.95-5.el5_9, but it looks like it is still in use. Is there any plan to move Perl DBD, mod_auth_mysql, ODBC, SASL, Dovecot, and PHP
from the 5.0 MySQL drivers to the 5.5 drivers?

Is there something that I missed in the upgrade process?

thanks

Matt mbrookov@mines.edu

8 thoughts on - MySQL 5.5, PHP And Other Tools Still Use 5.0 Client Drivers

  • 2013/10/28 Matthew B. Brookover

    Yes, you cannot remove mysql-5.0. see redhat knowledge base for more information.

  • Thanks Eero, Good to know.

    I did remove the rest of the 5.0 and 5.1 packages and will leave mysql-5.0-5.el5_9 in place for now. FYI, I searched through the rest of the installed packages, the only one that has the client library is mysql-5.0.95-5.el5_9.

    [root@w3 root]# rpm -qa | grep mysql | while read a; do echo $a; rpm -ql $a | grep libmysqlclient | sed ‘s/^/ /’; done mysql55-mysql-devel-5.5.32-3.el5
    mysql55-mysql-server-5.5.32-3.el5
    mysql55-runtime-1-12.el5
    mod_auth_mysql-3.0.0-3.2.el5_3
    mysql-connector-odbc-3.51.26r1127-2.el5
    mysql-5.0.95-5.el5_9
    /usr/lib/mysql/libmysqlclient.so.15
    /usr/lib/mysql/libmysqlclient.so.15.0.0
    /usr/lib/mysql/libmysqlclient_r.so.15
    /usr/lib/mysql/libmysqlclient_r.so.15.0.0
    mysql55-mysql-5.5.32-3.el5
    mysql55-mysql-bench-5.5.32-3.el5
    php53-mysql-5.3.3-21.el5
    mysql55-mysql-libs-5.5.32-3.el5
    mysql55-1-12.el5
    mysql-bench-5.0.95-5.el5_9
    mysql55-build-1-12.el5
    mysql55-mysql-test-5.5.32-3.el5
    [root@w3 root]#

    Matt

  • Am 28.10.2013 um 22:30 schrieb Matthew B. Brookover :

    php-mysql is linked against mysql-5.0-libs and talking to a mysql-5.5 server. Should this cause an unpredictable behavior?

  • Am 29.10.2013 um 22:56 schrieb Reindl Harald :

    In the last decade i saw very strange results while updating or doing similar things. the question above is more a theoretical thought despite the rational knowledge that in this example
    (communication-layer) the compatibility is preserved.

  • I have always tried to keep the client libraries in sync with the database in my own code. I was surprised that the upstream builders had mixed the 5.0 client with the 5.5 data base. I know of cases where library developers will provide for compatibility with various versions of protocols. It looks to me like this is one of those cases.

    We are using Perl and PHP with MySQL, and both seem to work with the 5.0
    client library on the 5.5 database.

    Besides the usual tests like create a new web page, delete a web page, edit a page, etc, we pointed a spider that is part of burp suite at the web site on a development system. The web site is several thousand pages, some are PHP with parts that are pulled from an upgraded mysql
    5.5 data base and others are flat files. Burp suite has been running for several hours and every thing looks good so far.

    I think this weekend, we will start moving production servers from CentOS 5.9 to 5.10 and from MySQL 5.0 to 5.5.

    Matt

  • If you look at the Software collections info for EL6, they specifically discuss that issue:

    http://dev.CentOS.org/CentOS/6/SCL/docs/#sect-Installation_and_Usage-Migrating_from_MySQL_5.1_to_MySQL_5.5

    (see section 2.6.3)

    So, Red Hat has specifically tested using the 5.1 (for EL6 and 5.0 for EL5) client library with the 5.5 database and has certified it as working enough that they support it.

    Does that mean it is flawless … likely not. But it is as intended.

LEAVE A COMMENT