[MDEV-13589] libmariadbclient18 is broken when using mariadb repo instead of debian's Created: 2017-08-19  Updated: 2017-10-30  Resolved: 2017-09-18

Status: Closed
Project: MariaDB Server
Component/s: libmariadb, Platform Debian
Affects Version/s: 10.1.24, 10.1.25, 10.1.26, 10.1.27, 10.1.28, 10.2.7, 10.2.8
Fix Version/s: 10.2.9

Type: Bug Priority: Blocker
Reporter: paladox Assignee: Sergei Golubchik
Resolution: Fixed Votes: 5
Labels: None
Environment:

debian stretch 9.1


Issue Links:
Problem/Incident
causes MDEV-13934 /usr/lib/x86_64-linux-gnu/libmariadbc... Confirmed
Relates
relates to MDEV-14225 After apt upgrade from 10.2.8 to 10.2... Closed

 Description   

Hi, when using libmariadbclient18 from mariadb repo, it causes it to not work on debian. I found this problem when using icinga2 as it is complaining with this error

[2017-08-19 15:46:37 +0000] critical/config: Error: Error while evaluating expression: Could not load library 'libdb_ido_mysql.so.2.7.0': libmariadbclient.so.18: cannot open shared object file: No such file or directory

But if i use libmariadbclient18 from debian https://packages.debian.org/stretch/amd64/libmariadbclient18/download it works.



 Comments   
Comment by Elena Stepanova [ 2017-08-20 ]

Could you please run and paste the output of dpkg -l | grep -iE 'mysql|maria' on the non-working installation?

Comment by Laurent Declercq [ 2017-08-22 ]

Related: https://jira.mariadb.org/browse/MDEV-13615

Comment by Laurent Declercq [ 2017-08-22 ]

Related: https://jira.mariadb.org/browse/MDEV-13588

Comment by Laurent Declercq [ 2017-08-22 ]

Related: https://jira.mariadb.org/browse/MDEV-12889

Comment by Laurent Declercq [ 2017-08-22 ]

I've not a cristal ball but I think that the error messsage reported here is due to the following:

  1. The user first installed the libmariadbclient18 package from your MariaDB 10.2 repository but this was not working due to the MDEV-13615 bug
  2. The user reinstalled the libmariadbclient18 package from the Debian repository and this worked
  3. The user wanted to report the issue here and so, he has reinstalled the libmariadbclient18 package from your MariaDB 10.2 repository and here come the error:

2017-08-19 15:46:37 +0000] critical/config: Error: Error while evaluating expression: Could not load library 'libdb_ido_mysql.so.2.7.0': libmariadbclient.so.18: cannot open shared object file: No such file or directory

I can easily reproduce such error in another context when doing the following

  1. Installing the libmariadbclient18 package from your MariaDB 10.2 repository
  2. Downgrading to libmariadbclient18 package from Debian repository
  3. Upgrading to libmariadbclient18 package from your MariaDB 10.2 repository

Result

root@stretch:/var/log/imscp# LANG=C perl /var/www/imscp/engine/imscp-rqst-mngr -v
[DEBUG] iMSCP::Bootstrapper::boot: Booting backend....
[DEBUG] iMSCP::LockFile::acquire: Acquiring exclusive lock on /var/lock/imscp.lock
[DEBUG] iMSCP::LockFile::release: Releasing exclusive lock on /var/lock/imscp.lock
[FATAL] iMSCP::Database::mysql::getRawDb: Couldn't connect to SQL server: install_driver(mysql) failed: Can't load '/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/DBD/mysql/mysql.so' for module DBD::mysql: libmariadbclient.so.18: cannot open shared object file: No such file or directory at /usr/lib/x86_64-linux-gnu/perl/5.24/DynaLoader.pm line 187, <$fh> line 406.
 at (eval 58) line 3.
Compilation failed in require at (eval 58) line 3, <$fh> line 406.
Perhaps a required shared library or dll isn't installed where expected
 at /var/www/imscp/engine/PerlLib/iMSCP/Database/mysql.pm line 100.
	...propagated at /var/www/imscp/engine/PerlLib/iMSCP/Database/mysql.pm line 105, <$fh> line 406.

As you can see here, the error is identical but raised from another library. You can fix that by doing:

apt-get install --reinstall libmariadb3

but once after, the error become as the one showed in the MDEV-13615 bug:

root@stretch:/var/log/imscp# LANG=C perl /var/www/imscp/engine/imscp-rqst-mngr -v
[DEBUG] iMSCP::Bootstrapper::boot: Booting backend....
[DEBUG] iMSCP::LockFile::acquire: Acquiring exclusive lock on /var/lock/imscp.lock
[DEBUG] iMSCP::LockFile::release: Releasing exclusive lock on /var/lock/imscp.lock
[FATAL] iMSCP::Database::mysql::getRawDb: Couldn't connect to SQL server: install_driver(mysql) failed: Can't load '/usr/lib/x86_64-linux-gnu/perl5/5.24/auto/DBD/mysql/mysql.so' for module DBD::mysql: /usr/lib/x86_64-linux-gnu/libmariadbclient.so.18: version `libmariadbclient_18' not found (required by /usr/lib/x86_64-linux-gnu/perl5/5.24/auto/DBD/mysql/mysql.so) at /usr/lib/x86_64-linux-gnu/perl/5.24/DynaLoader.pm line 187, <$fh> line 406.
 at (eval 58) line 3.
Compilation failed in require at (eval 58) line 3, <$fh> line 406.
Perhaps a required shared library or dll isn't installed where expected
 at /var/www/imscp/engine/PerlLib/iMSCP/Database/mysql.pm line 100.
	...propagated at /var/www/imscp/engine/PerlLib/iMSCP/Database/mysql.pm line 105, <$fh> line 406.

Hope this will help you

Comment by Michiel Hazelhof [ 2017-09-08 ]

Affected versions should read 10.1.28 too.

Comment by Sergei Golubchik [ 2017-09-10 ]

otto, could you review this my change to debian packaging?
It should be released next week, so try to do is asap, please.

Thanks!

Comment by Otto Kekäläinen [ 2017-09-10 ]

serg I don't see an attached patch or a link to a patch/Github so I don't know what to review.

Comment by Sergei Golubchik [ 2017-09-10 ]

In the right pane, there's a link to commit. But here it is, again: https://github.com/mariadb/server/commit/8da9356a010a9

Comment by Otto Kekäläinen [ 2017-09-10 ]

Roger that.

In the long term we are trying to close the delta between what is in downstream distros and upstream MariaDB, and that work currently targets the 10.3 dev branch (mostly done by oerdnj at the moment). This includes unifying the names and contents of the packages, and having the compat packages. As a fix for 10.2 at this point the commit https://github.com/mariadb/server/commit/8da9356a010a92bfd85fc4987cd057b03a0f07e6 seems fine to me.

Generated at Thu Feb 08 08:06:47 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.