ldconfig mysql_mysql: error while loading shared libraries: libmysqlclient.so.16

mysql卸载后重装报错:

[root@localhost]# mysql

mysql: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No such file or directory

1. checking for libmysqlclient installed.

[root@node01 mysqli]# ldconfig -v | grep mysql

/usr/lib64/mysql:

libmysqlclient_r.so.16 -> libmysqlclient_r.so.16.0.0

libmysqlclient.so.16 -> libmysqlclient.so.16.0.0

[root@node01 mysqli]#

[root@node01 mysqli]#locate libmysqlclient.so

/usr/lib64/mysql/libmysqlclient.so

/usr/lib64/mysql/libmysqlclient.so.16

/usr/lib64/mysql/libmysqlclient.so.16.0.0

[root@node01 mysqli]#

if output empty then simply run these commands on rpm\yum based linux:1.17.0) 4.7.3 20121001 (prerelease)Copyright (C) 2012 Free Software Foundation, Inc.This is free software; see the source for copying conditions. There is NOwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. co

yum install mysql-devel mysql-libs

2. re-compile php-mysql module with path to lib64 folder.

./configure �with-php-config=/usr/local/php/bin/php-config �with-mysql=/usr/bin/ �with-libdir=lib64

3. alternative solution is:

[root@node01 mysql]#ln -s /usr/lib64/mysql/libmysqlclient.so /usr/lib/mysql/libmysqlclient.so

This entry was posted in CentOS, Fedora, Linux, MySQL, OS, RedHat by stealth. Bookmark the permalink.

talled it successfully on one system, but when I tried to install it on another, its throwing up some really random error. I initially installed mysql and made sure its running. Then I installed sysbench with the command: dnf install sysben

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值