Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[solved] error with shared libraries libmysqlclient.so.18

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
maxbre
Posts: 76
Joined: 2014-11-08 16:44

[solved] error with shared libraries libmysqlclient.so.18

#1 Post by maxbre »

I recently moved fom mysql to mariadb and everything went perfectly smooth apart from that qgis is now no longer working (not starting at all)

I got the following message when trying to start qgis

Code: Select all

 qgis
/usr/bin/qgis.bin: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory
may be a missing shared library??

apparently is already there because...

Code: Select all

sudo apt-get install libmysqlclient18
Lettura elenco dei pacchetti... Fatto
Generazione albero delle dipendenze       
Lettura informazioni sullo stato... Fatto
libmysqlclient18 è già alla versione più recente.
0 aggiornati, 0 installati, 0 da rimuovere e 0 non aggiornati.
3 non completamente installati o rimossi.
Dopo quest'operazione, verranno occupati 0 B di spazio su disco.
Continuare? [S/n] s
Configurazione di qgis-providers (1:2.18.9+13jessie)...
/usr/lib/qgis/crssync: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory
dpkg: errore nell'elaborare il pacchetto qgis-providers (--configure):
 il sottoprocesso installato script di post-installation ha restituito lo stato di errore 127
dpkg: problemi con le dipendenze impediscono la configurazione di qgis:
 qgis dipende da qgis-providers (= 1:2.18.9+13jessie); comunque:
  Il pacchetto qgis-providers non è ancora configurato.

dpkg: errore nell'elaborare il pacchetto qgis (--configure):
 problemi con le dipendenze - lasciato non configurato
dpkg: problemi con le dipendenze impediscono la configurazione di qgis-plugin-grass:
 qgis-plugin-grass dipende da qgis (= 1:2.18.9+13jessie); comunque:
  Il pacchetto qgis non è ancora configurato.

dpkg: errore nell'elaborare il pacchetto qgis-plugin-grass (--configure):
 problemi con le dipendenze - lasciato non configurato
Si sono verificati degli errori nell'elaborazione:
 qgis-providers
 qgis
 qgis-plugin-grass
E: Sub-process /usr/bin/dpkg returned an error code (1)
mbressan@arpa.veneto.it@TVDLND062:~$ sudo apt-get install libmysqlclient18 >error.txt
s
E: Sub-process /usr/bin/dpkg returned an error code (1)
any ideas how to fix that?

I've been trying to reinstall qgis but without any success

this is my configuration (at the end of a long and winding road...)

Code: Select all

Linux 4.9.0-0.bpo.3-amd64 #1 SMP Debian 4.9.25-1~bpo8+1 (2017-05-19) x86_64 GNU/Linux
any help please please?
:oops:
Last edited by maxbre on 2017-06-15 07:47, edited 1 time in total.

User avatar
phenest
Posts: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: error with shared libraries libmysqlclient.so.18

#2 Post by phenest »

Code: Select all

apt-get -f install
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D

maxbre
Posts: 76
Joined: 2014-11-08 16:44

Re: error with shared libraries libmysqlclient.so.18

#3 Post by maxbre »

I've been trying that, it doesn' work! :cry:

User avatar
phenest
Posts: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: error with shared libraries libmysqlclient.so.18

#4 Post by phenest »

How doesn't it work? Explain.

And could you translate some of that output to English please.
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D

maxbre
Posts: 76
Joined: 2014-11-08 16:44

Re: error with shared libraries libmysqlclient.so.18

#5 Post by maxbre »

tomorrow I'll try to post more detailed informations, thanks

Dai_trying
Posts: 1101
Joined: 2016-01-07 12:25
Has thanked: 5 times
Been thanked: 16 times

Re: error with shared libraries libmysqlclient.so.18

#6 Post by Dai_trying »

If you need to get your terminal output into english for posting here try typing LC_ALL=C then a space and the command you want to issue, this should allow us to understand better. :)

maxbre
Posts: 76
Joined: 2014-11-08 16:44

Re: error with shared libraries libmysqlclient.so.18

#7 Post by maxbre »

this is what I've got

Code: Select all

 LC_ALL=C sudo apt-get -f install 

Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
3 not fully installed or removed.

After this operation, 0 B of additional disk space will be used.
Setting up qgis-providers (1:2.18.9+13jessie) ...
/usr/lib/qgis/crssync: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory

dpkg: error processing package qgis-providers (--configure):
 subprocess installed post-installation script returned error exit status 127

dpkg: dependency problems prevent configuration of qgis:
 qgis depends on qgis-providers (= 1:2.18.9+13jessie); however:
  Package qgis-providers is not configured yet.

dpkg: error processing package qgis (--configure):
 dependency problems - leaving unconfigured

dpkg: dependency problems prevent configuration of qgis-plugin-grass:
 qgis-plugin-grass depends on qgis (= 1:2.18.9+13jessie); however:
  Package qgis is not configured yet.

dpkg: error processing package qgis-plugin-grass (--configure):
 dependency problems - leaving unconfigured

Errors were encountered while processing:
 qgis-providers
 qgis
 qgis-plugin-grass

E: Sub-process /usr/bin/dpkg returned an error code (1)

no way to install those packages...
what do you think about manually copying somewhere (where, that's the problem!) the shared libraries libmysqlclient.so.18 (and how to get that file that's another problem)?

desperately lost in the missing dependencies
:shock:

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: error with shared libraries libmysqlclient.so.18

#8 Post by orythem27 »

maxbre wrote:I recently moved fom mysql to mariadb
Could you describe this move as detailed as possible? If you were following a tutorial then please post the link.
maxbre wrote:/usr/bin/qgis.bin: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or director
See detailed infomation with

Code: Select all

strace qgis 2>&1 | grep mysql
find /usr/lib/ | grep 'mysql\|maria' | xargs -r ls -l

maxbre
Posts: 76
Joined: 2014-11-08 16:44

Re: error with shared libraries libmysqlclient.so.18

#9 Post by maxbre »

I followed this recipe to install mariadb on top of mysql

https://mariadb.com/resources/blog/how- ... five-steps
https://downloads.mariadb.org/mariadb/r ... rsion=10.2

everything went apparently fine, apart for qgis...

Code: Select all

LC_ALL=C find /usr/lib/ | grep 'mysql\|maria' | xargs -r ls -l

-rwxr-xr-x 1 root root   27264 Sep  5  2014 /usr/lib/grass64/driver/db/mysql
-rw-r--r-- 1 root root  241688 Jun  1 19:09 /usr/lib/libreoffice/program/libmysqllo.so
-rw-r--r-- 1 root root    8372 Apr 25 22:44 /usr/lib/libreoffice/share/config/soffice.cfg/dbaccess/ui/dbwizmysqlintropage.ui
-rw-r--r-- 1 root root    3982 Apr 25 22:44 /usr/lib/libreoffice/share/config/soffice.cfg/dbaccess/ui/dbwizmysqlnativepage.ui
-rw-r--r-- 1 root root    9626 Apr 25 22:44 /usr/lib/libreoffice/share/config/soffice.cfg/dbaccess/ui/mysqlnativepage.ui
-rw-r--r-- 1 root root   11245 Apr 25 22:44 /usr/lib/libreoffice/share/config/soffice.cfg/dbaccess/ui/mysqlnativesettings.ui
-rw-r--r-- 1 root root   10312 May 15 02:16 /usr/lib/mysql/plugin/auth_pam.so
-rw-r--r-- 1 root root    6136 May 15 02:16 /usr/lib/mysql/plugin/auth_socket.so
-rw-r--r-- 1 root root   10096 May 15 02:16 /usr/lib/mysql/plugin/dialog.so
-rw-r--r-- 1 root root   18848 May 15 02:16 /usr/lib/mysql/plugin/file_key_management.so
-rw-r--r-- 1 root root   92448 May 15 02:16 /usr/lib/mysql/plugin/ha_archive.so
-rw-r--r-- 1 root root   68008 May 15 02:16 /usr/lib/mysql/plugin/ha_blackhole.so
-rw-r--r-- 1 root root 1629568 May 15 02:16 /usr/lib/mysql/plugin/ha_connect.so
-rw-r--r-- 1 root root   92632 May 15 02:16 /usr/lib/mysql/plugin/ha_federated.so
-rw-r--r-- 1 root root  125152 May 15 02:16 /usr/lib/mysql/plugin/ha_federatedx.so
-rw-r--r-- 1 root root  162168 May 15 02:16 /usr/lib/mysql/plugin/ha_sphinx.so
-rw-r--r-- 1 root root  216640 May 15 02:16 /usr/lib/mysql/plugin/handlersocket.so
-rw-r--r-- 1 root root   10616 May 15 02:16 /usr/lib/mysql/plugin/locales.so
-rw-r--r-- 1 root root   10616 May 15 02:16 /usr/lib/mysql/plugin/metadata_lock_info.so
-rw-r--r-- 1 root root    6000 May 15 02:16 /usr/lib/mysql/plugin/mysql_clear_password.so
-rw-r--r-- 1 root root   11216 May 15 02:16 /usr/lib/mysql/plugin/query_cache_info.so
-rw-r--r-- 1 root root   10792 May 15 02:16 /usr/lib/mysql/plugin/query_response_time.so
-rw-r--r-- 1 root root   64784 May 15 02:16 /usr/lib/mysql/plugin/semisync_master.so
-rw-r--r-- 1 root root   14664 May 15 02:16 /usr/lib/mysql/plugin/semisync_slave.so
-rw-r--r-- 1 root root   59856 May 15 02:16 /usr/lib/mysql/plugin/server_audit.so
-rw-r--r-- 1 root root   10584 May 15 02:16 /usr/lib/mysql/plugin/simple_password_check.so
-rw-r--r-- 1 root root   10712 May 15 02:16 /usr/lib/mysql/plugin/sql_errlog.so
-rw-r--r-- 1 root root   10968 May 15 02:16 /usr/lib/mysql/plugin/wsrep_info.so
-rw-r--r-- 1 root root   56152 Feb  8 10:07 /usr/lib/php5/20131226/mysql.so
-rw-r--r-- 1 root root  150824 Feb  8 10:07 /usr/lib/php5/20131226/mysqli.so
-rw-r--r-- 1 root root  281728 Feb  8 10:07 /usr/lib/php5/20131226/mysqlnd.so
-rw-r--r-- 1 root root   31752 Feb  8 10:07 /usr/lib/php5/20131226/pdo_mysql.so
-rwxr-xr-x 1 root root     196 Jan 20  2012 /usr/lib/pkgconfig/mysql-connector-net.pc
-rw-r--r-- 1 root root  557010 Jul 19  2014 /usr/lib/x86_64-linux-gnu/libmariadb.a
lrwxrwxrwx 1 root root      15 Jul 19  2014 /usr/lib/x86_64-linux-gnu/libmariadb.so -> libmariadb.so.2
-rw-r--r-- 1 root root  287408 Jul 19  2014 /usr/lib/x86_64-linux-gnu/libmariadb.so.2
-rw-r--r-- 1 root root  340304 May 15 02:16 /usr/lib/x86_64-linux-gnu/libmariadb.so.3
lrwxrwxrwx 1 root root      15 May 15 02:16 /usr/lib/x86_64-linux-gnu/libmariadbclient.so.18 -> libmariadb.so.3
lrwxrwxrwx 1 root root      15 May 15 02:16 /usr/lib/x86_64-linux-gnu/libmysqlclient.so.19 -> libmariadb.so.3
lrwxrwxrwx 1 root root      15 May 15 02:16 /usr/lib/x86_64-linux-gnu/libmysqlclient.so.20 -> libmariadb.so.3
-rw-r--r-- 1 root root   73520 May  4  2015 /usr/lib/x86_64-linux-gnu/qt4/plugins/sqldrivers/libqsqlmysql.so

/usr/lib/mysql:
total 4
drwxr-xr-x 2 root root 4096 Jun 13 16:40 plugin

/usr/lib/mysql/plugin:
total 2624
-rw-r--r-- 1 root root   10312 May 15 02:16 auth_pam.so
-rw-r--r-- 1 root root    6136 May 15 02:16 auth_socket.so
-rw-r--r-- 1 root root   10096 May 15 02:16 dialog.so
-rw-r--r-- 1 root root   18848 May 15 02:16 file_key_management.so
-rw-r--r-- 1 root root   92448 May 15 02:16 ha_archive.so
-rw-r--r-- 1 root root   68008 May 15 02:16 ha_blackhole.so
-rw-r--r-- 1 root root 1629568 May 15 02:16 ha_connect.so
-rw-r--r-- 1 root root   92632 May 15 02:16 ha_federated.so
-rw-r--r-- 1 root root  125152 May 15 02:16 ha_federatedx.so
-rw-r--r-- 1 root root  162168 May 15 02:16 ha_sphinx.so
-rw-r--r-- 1 root root  216640 May 15 02:16 handlersocket.so
-rw-r--r-- 1 root root   10616 May 15 02:16 locales.so
-rw-r--r-- 1 root root   10616 May 15 02:16 metadata_lock_info.so
-rw-r--r-- 1 root root    6000 May 15 02:16 mysql_clear_password.so
-rw-r--r-- 1 root root   11216 May 15 02:16 query_cache_info.so
-rw-r--r-- 1 root root   10792 May 15 02:16 query_response_time.so
-rw-r--r-- 1 root root   64784 May 15 02:16 semisync_master.so
-rw-r--r-- 1 root root   14664 May 15 02:16 semisync_slave.so
-rw-r--r-- 1 root root   59856 May 15 02:16 server_audit.so
-rw-r--r-- 1 root root   10584 May 15 02:16 simple_password_check.so
-rw-r--r-- 1 root root   10712 May 15 02:16 sql_errlog.so
-rw-r--r-- 1 root root   10968 May 15 02:16 wsrep_info.so


User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: error with shared libraries libmysqlclient.so.18

#10 Post by orythem27 »

maxbre wrote: /usr/lib/x86_64-linux-gnu/libmariadb.so.3
/usr/lib/x86_64-linux-gnu/libmariadbclient.so.18 -> libmariadb.so.3
/usr/lib/x86_64-linux-gnu/libmysqlclient.so.19 -> libmariadb.so.3
/usr/lib/x86_64-linux-gnu/libmysqlclient.so.20 -> libmariadb.so.3
Try this as root:

Code: Select all

ln -s /usr/lib/x86_64-linux-gnu/libmariadb.so.3 /usr/lib/x86_64-linux-gnu/libmysqlclient.so.18
This way you will be using the mariadb client library instead of mysql client library. IIRC the former has more features (e.g. async support) and can be used as a drop-in replacement for the mysql client library.

Or, you could try `apt install --reinstall libmysqlclient18` to revert to the "real" libmysqlclient.so.18. Force a reinstall is necessary because its file might have been modified by the foreign mariadb packages and the package manager didn't know about that. Disclaimer: I did not try that. Maybe libmysqlclient18 is not co-installable with the foreign mariadb packages. And the reason why those foreign mariadb packages would wipe files from libmysqlclient18 is unclear.
Last edited by orythem27 on 2017-06-15 07:44, edited 1 time in total.

maxbre
Posts: 76
Joined: 2014-11-08 16:44

Re: error with shared libraries libmysqlclient.so.18

#11 Post by maxbre »

woooow, thanksss a looot!

you saved my life!

so you suggested to set up a symbolic link between libmariadb.so.3 and libmysqlclient.so.18

great, it seems working perfectly now

thanks again

leveret
Posts: 9
Joined: 2017-06-26 10:56

Re: [solved] error with shared libraries libmysqlclient.so.1

#12 Post by leveret »

I have just upgraded my jessie to stretch and it replaces mysql with mariadb.

I want to try your suggestion to link libmariadb.so.3 and libmysqlclient.so.18

my question is, which package contains libmariadb.so.3 ? I searched and could not find it.

User avatar
orythem27
Posts: 252
Joined: 2017-05-11 07:59
Location: P.R. China

Re: [solved] error with shared libraries libmysqlclient.so.1

#13 Post by orythem27 »

leveret wrote:which package contains libmariadb.so.3 ?
OP is installing mariadb on jessie from an external repo.

Post Reply