RHEL 6.5, perl-DBD-MySQL not working as libmysqlclient_16 is not provided

Bug #1382100 reported by Kenny Gryp
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.5
New
Undecided
Unassigned
5.6
Confirmed
Undecided
Unassigned
5.7
New
Undecided
Unassigned

Bug Description

On RHEL 6.5

# cat test.pl
#!/bin/env perl

use DBI;

$dsn = "DBI:mysql:database=sysbench;host=localhost;port=3306";
$dbh = DBI->connect($dsn, 'root', 'root');

# perl test.pl
install_driver(mysql) failed: Can't load '/usr/lib64/perl5/vendor_perl/auto/DBD/mysql/mysql.so' for module DBD::mysql: /usr/lib64/libmysqlclient.so.18: version `libmysqlclient_16' not found (required by /usr/lib64/perl5/vendor_perl/auto/DBD/mysql/mysql.so) at /usr/lib64/perl5/DynaLoader.pm line 200.
 at (eval 3) line 3
Compilation failed in require at (eval 3) line 3.
Perhaps a required shared library or dll isn't installed where expected
 at test.pl line 8

# rpm -ql Percona-Server-shared-56
/usr/lib64/libperconaserverclient.so.18
/usr/lib64/libperconaserverclient.so.18.1.0
/usr/lib64/libperconaserverclient_r.so.18
/usr/lib64/libperconaserverclient_r.so.18.1.0

(there are symlinks from /usr/lib64/libmysqlclient.so.18 to libperconaserverclient.so.18)

# rpm -qV perl-DBD-MySQL
Unsatisfied dependencies for perl-DBD-MySQL-4.020-1.el6.x86_64: libmysqlclient.so.18(libmysqlclient_16)(64bit) is needed by
             perl-DBD-MySQL-4.020-1.el6.x86_64

# rpm -q --provides Percona-Server-shared-56
libmysqlclient.so.18()(64bit)
libmysqlclient.so.18(libmysqlclient_18)(64bit)
libperconaserverclient.so.18()(64bit)
libperconaserverclient.so.18(libperconaserverclient_18)(64bit)
Percona-Server-shared-56 = 5.6.21-rel69.0.el6
Percona-Server-shared-56(x86-64) = 5.6.21-rel69.0.el6

Percona-Server-shared-compat-51 doesn't provide the library:

# rpm -qp --provides Percona-Server-shared-compat-51-5.1.73-rel14.12.624.rhel6.x86_64.rpm
warning: Percona-Server-shared-compat-51-5.1.73-rel14.12.624.rhel6.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID cd2efd2a: NOKEY
MySQL-shared
libmysqlclient.so.12()(64bit)
libmysqlclient.so.14()(64bit)
libmysqlclient.so.14(libmysqlclient_14)(64bit)
libmysqlclient.so.15()(64bit)
libmysqlclient.so.15(libmysqlclient_15)(64bit)
libmysqlclient_r.so.12()(64bit)
libmysqlclient_r.so.14()(64bit)
libmysqlclient_r.so.14(libmysqlclient_14)(64bit)
libmysqlclient_r.so.15()(64bit)
libmysqlclient_r.so.15(libmysqlclient_15)(64bit)
Percona-Server-shared-compat-51 = 5.1.73-rel14.12.624.rhel6
Percona-Server-shared-compat-51(x86-64) = 5.1.73-rel14.12.624.rhel6

the packages from RHEL provide this:

# rpm -qp --provides /opt/repo/Packages/mysql-libs-5.1.71-1.el6.x86_64.rpm
config(mysql-libs) = 5.1.71-1.el6
libmysqlclient.so.16()(64bit)
libmysqlclient.so.16(libmysqlclient_16)(64bit)
libmysqlclient_r.so.16()(64bit)
libmysqlclient_r.so.16(libmysqlclient_16)(64bit)
mysql-libs = 5.1.71-1.el6
mysql-libs(x86-64) = 5.1.71-1.el6

tags: added: pkg
Revision history for this message
Muhammad Irfan (muhammad-irfan) wrote :

[root@centos ~]# cat /etc/*release*
CentOS release 6.5 (Final)

Percona-Server-shared-51 provides the required libmysqlclient.so.16

[root@centos ~]# rpm -q --provides Percona-Server-shared-51
MySQL-shared
Percona-XtraDB-shared
libmysqlclient.so.16()(64bit)
libmysqlclient.so.16(libmysqlclient_16)(64bit)
libmysqlclient_r.so.16()(64bit)
libmysqlclient_r.so.16(libmysqlclient_16)(64bit)
mysql-libs
mysql-shared

[root@centos ~]# cat test.pl
#!/bin/env perl

use DBI;

$dsn = "DBI:mysql:database=test;host=localhost;port=3306";
$dbh = DBI->connect($dsn, 'irfan', 'irfan');

[root@centos ~]# perl test.pl
install_driver(mysql) failed: Can't load '/usr/lib64/perl5/auto/DBD/mysql/mysql.so' for module DBD::mysql: libmysqlclient.so.16: cannot open shared object file: No such file or directory at /usr/lib64/perl5/DynaLoader.pm line 200.
 at (eval 3) line 3
Compilation failed in require at (eval 3) line 3.
Perhaps a required shared library or dll isn't installed where expected
 at test.pl line 6

[root@centos ~]# rpm -qV perl-DBD-MySQL
Unsatisfied dependencies for perl-DBD-MySQL-4.013-3.el6.x86_64:
        libmysqlclient.so.16()(64bit) is needed by perl-DBD-MySQL-4.013-3.el6.x86_64
        libmysqlclient.so.16(libmysqlclient_16)(64bit) is needed by perl-DBD-MySQL-4.013-3.el6.x86_64

But as soon as i install Percona-Server-shared-51 it installs libmysqlclient.so.16 and works as expected.

[root@centos ~]# perl test.pl
[root@centos ~]#

When you try to install perl-DBD-MySQL via yum it installs Percona-Server-shared-51 as dependency.

[root@centos ~]# yum install perl-DBD-MySQL
=====================================================================================================================================================================================================
 Package Arch Version Repository Size
=====================================================================================================================================================================================================
Installing:
 perl-DBD-MySQL x86_64 4.013-3.el6 base 134 k
Installing for dependencies:
 Percona-Server-shared-51 x86_64 5.1.73-rel14.12.624.rhel6 percona-release-x86_64 2.1 M
 perl-DBI x86_64 1.609-4.el6 base 705 k

Transaction Summary
=====================================================================================================================================================================================================
Install 3 Package(s)

Changed in percona-server:
status: New → Incomplete
Revision history for this message
Kenny Gryp (gryp) wrote :

Hello Muhammad,

yes, I have seen this work in CentOS as well without any problems.

However, this system is RedHat Enterprise Linux 6.5, coming from an upgrade from 6.3.

Can you test this please?

Kenny

Changed in percona-server:
status: Incomplete → New
Revision history for this message
Muhammad Irfan (muhammad-irfan) wrote :

[root@localhost mysql]# cat /etc/*release*
Red Hat Enterprise Linux Server release 6.5 (Santiago)

[root@localhost mysql]# rpm -q --provides Percona-Server-shared-56
libmysqlclient.so.18()(64bit)
libmysqlclient.so.18(libmysqlclient_18)(64bit)
libperconaserverclient.so.18()(64bit)
libperconaserverclient.so.18(libperconaserverclient_18)(64bit)
Percona-Server-shared-56 = 5.6.22-rel72.0.el6
Percona-Server-shared-56(x86-64) = 5.6.22-rel72.0.el6

[root@localhost mysql]# rpm -q --provides Percona-Server-shared-51
MySQL-shared
Percona-XtraDB-shared
libmysqlclient.so.16()(64bit)
libmysqlclient.so.16(libmysqlclient_16)(64bit)
libmysqlclient_r.so.16()(64bit)
libmysqlclient_r.so.16(libmysqlclient_16)(64bit)
mysql-libs
mysql-shared
Percona-Server-shared-51 = 5.1.73-rel14.12.624.rhel6
Percona-Server-shared-51(x86-64) = 5.1.73-rel14.12.624.rhel6

[root@localhost mysql]# rpm -q --provides Percona-Server-shared-compat-51
MySQL-shared
libmysqlclient.so.12()(64bit)
libmysqlclient.so.14()(64bit)
libmysqlclient.so.14(libmysqlclient_14)(64bit)
libmysqlclient.so.15()(64bit)
libmysqlclient.so.15(libmysqlclient_15)(64bit)
libmysqlclient_r.so.12()(64bit)
libmysqlclient_r.so.14()(64bit)
libmysqlclient_r.so.14(libmysqlclient_14)(64bit)
libmysqlclient_r.so.15()(64bit)
libmysqlclient_r.so.15(libmysqlclient_15)(64bit)
Percona-Server-shared-compat-51 = 5.1.73-rel14.12.624.rhel6
Percona-Server-shared-compat-51(x86-64) = 5.1.73-rel14.12.624.rhel6

Percona-server-shared-compat doesn't provides libmysqlclient.so.16 while Percona-server-shared does and mysql-libs provides libmysqlclient.so.16

Revision history for this message
monty solomon (monty+launchpad) wrote :

This bug appears to be related to bug 1199534

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-3192

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.