今天在给客户部署Mysql8.0.26最高版本时候,遇到mysqld: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory 特总结以下内容,详细记录了升级openssl的全过程
1.现象
[root@jeames mysql]# mysqld --initialize
mysqld: error while loading shared libraries: libssl.so.1.1: cannot open shared object file:
No such file or directory
2. 处理过程
2.1 确认版本
[root@jeames]# openssl version
OpenSSL 1.0.0 21 Apr 202
--下载网址 https://www.openssl.org/source/openssl-1.1.1g.tar.gz --编译 openssl tar -xvf openssl-1.1.1g.tar.gz cd openssl-1.1.1g ./config shared --openssldir=/usr/local/openssl --prefix=/usr/local/openssl make && make install --配置 echo "/usr/local/lib64/" >> /etc/ld.so.conf ldconfig mv /usr/bin/openssl /usr/bin/openssl.old ln -s /usr/local/openssl/bin/openssl /usr/bin/openssl ln -s /usr/local/openssl/include/openssl /usr/include/openssl echo "/usr/local/openssl/lib" >> /etc/ld.so.conf ldconfig -v
2.2 升级后版本
[root@jeames]# openssl version
OpenSSL 1.1.1g 21 Apr 2020