一、原因

由于在编译mysql时,报ssl错误,于是想卸载openssl再重新安装

rpm -qa|grep openssl
rpm -e openssl-1.0.2k-.el7_6..x86_64
rpm -e openssl-1.0.2k-.el7_6..x86_64 --nodeps
rpm -e openssl-libs-1.0.2k-.el7_6..x86_64 --nodeps
rpm -e openssl-devel-1.0.2k-.el7_6..x86_64 --nodeps

二、报错

此时再执行yum报错

[root@server- lib64]# yum install openssl
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was: libcrypto.so.: cannot open shared object file: No such file or directory Please install a package which provides this module, or
verify that the module is installed correctly. It's possible that the above module doesn't match the
current version of Python, which is:
2.7. (default, Oct , ::)
[GCC 4.8. (Red Hat 4.8.-)] If you cannot solve this problem yourself, please go to
the yum faq at:
http://yum.baseurl.org/wiki/Faq

系统找不到ssl库,所以不能使用命令,不能yum只能rpm本地安装

三、 下载openssl-libs-1.0.2k-12.el7.x86_64.rpm包

下载地址:http://rpmfind.net/linux/centos/7.6.1810/updates/x86_64/Packages/openssl-libs-1.0.2k-16.el7_6.1.x86_64.rpm

先下载到本地电脑,通过rz上传到服务器

四、安装

[root@server- src]# rpm -ivh openssl-libs-1.0.2k-.el7_6..x86_64.rpm
准备中... ################################# [%]
软件包 openssl-libs-:1.0.2k-.el7_6..x86_64 已经安装

五、再执行yum openssl

[root@server- src]# yum search openssl
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.bit.edu.cn
* extras: mirror.bit.edu.cn
* updates: mirror.bit.edu.cn
========================================== N/S matched: openssl ===========================================
apr-util-openssl.x86_64 : APR utility library OpenSSL crytpo support
openssl-devel.i686 : Files for development of applications which will use OpenSSL
openssl-devel.x86_64 : Files for development of applications which will use OpenSSL
openssl-perl.x86_64 : Perl scripts provided with OpenSSL
openssl-static.i686 : Libraries for static linking of applications which will use OpenSSL
openssl-static.x86_64 : Libraries for static linking of applications which will use OpenSSL
perl-Crypt-OpenSSL-Bignum.x86_64 : Perl interface to OpenSSL for Bignum
perl-Crypt-OpenSSL-RSA.x86_64 : Perl interface to OpenSSL for RSA
perl-Crypt-OpenSSL-Random.x86_64 : Perl interface to OpenSSL for Random
pyOpenSSL.x86_64 : Python wrapper module around the OpenSSL library
pyOpenSSL-doc.noarch : Documentation for pyOpenSSL
xmlsec1-openssl.i686 : OpenSSL crypto plugin for XML Security Library
xmlsec1-openssl.x86_64 : OpenSSL crypto plugin for XML Security Library
xmlsec1-openssl-devel.i686 : OpenSSL crypto plugin for XML Security Library
xmlsec1-openssl-devel.x86_64 : OpenSSL crypto plugin for XML Security Library
m2crypto.x86_64 : Support for using OpenSSL in python scripts
nss_compat_ossl.i686 : Source-level compatibility library for OpenSSL to NSS porting
nss_compat_ossl.x86_64 : Source-level compatibility library for OpenSSL to NSS porting
openssl.x86_64 : Utilities from the general purpose cryptography library with TLS implementation
openssl-libs.i686 : A general purpose cryptography library with TLS implementation
openssl-libs.x86_64 : A general purpose cryptography library with TLS implementation
openssl098e.i686 : A compatibility version of a general cryptography and TLS library
openssl098e.x86_64 : A compatibility version of a general cryptography and TLS library
perl-Crypt-SSLeay.x86_64 : Crypt::SSLeay - OpenSSL glue that provides LWP https support
perl-Net-SSLeay.x86_64 : Perl extension for using OpenSSL
qca-ossl.i686 : OpenSSL plugin for the Qt Cryptographic Architecture v2
qca-ossl.x86_64 : OpenSSL plugin for the Qt Cryptographic Architecture v2 名称和简介匹配 only,使用“search all”试试。
[root@server- src]# history|grep rpm
rpm -qa|grep mysql
wget https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-community-server-5.7.26-1.el7.x86_64.rpm
yum install rpm
wget https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-community-server-5.7.26-1.el7.x86_64.rpm
rm -rf mysql-community-server-5.7.-.el7.x86_64.rpm.
rm -rf mysql-community-server-5.7.-.el7.x86_64.rpm.
wget https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-community-client-5.7.26-1.el7.x86_64.rpm
rpm -e mariadb-libs-:5.5.-.el7_5.x86_64 --nodeps
rpm -ivh mysql-community-common-5.7.-.el7.x86_64.rpm
rpm -ivh mysql-community-libs-5.7.-.el7.x86_64.rpm
rpm -ivh mysql-community-client-5.7.-.el7.x86_64.rpm
rpm -ivh mysql-community-server-5.7.-.el7.x86_64.rpm
rpm -qa|grep openssl
rpm -e openssl-1.0.2k-.el7_6..x86_64
rpm -e openssl-1.0.2k-.el7_6..x86_64 --nodeps
rpm -e openssl-libs-1.0.2k-.el7_6..x86_64 --nodeps
rpm -e openssl-devel-1.0.2k-.el7_6..x86_64 --nodeps
rpm -qa|grep openssl
rpm -ivh openssl-libs-1.0.2k-.el7.x86_64.rpm --force
wget http://rpmfind.net/linux/centos/7.6.1810/updates/x86_64/Packages/openssl-libs-1.0.2k-16.el7_6.1.x86_64.rpm
rm p-ivh openssl-libs-1.0.2k-.el7_6..x86_64.rpm
rpm -ivh openssl-libs-1.0.2k-.el7_6..x86_64.rpm
history|grep rpm
[root@server- src]# rpm -qa|grep openssl
openssl-libs-1.0.2k-.el7_6..x86_64
[root@server- src]# rpm -ivh openssl-libs-1.0.2k-.el7_6..x86_64.rpm
准备中... ################################# [%]
软件包 openssl-libs-:1.0.2k-.el7_6..x86_64 已经安装
[root@server- src]# yum install openssl
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.bit.edu.cn
* extras: mirror.bit.edu.cn
* updates: mirror.bit.edu.cn
正在解决依赖关系
--> 正在检查事务
---> 软件包 openssl.x86_64.1.1..2k-.el7_6. 将被 安装
--> 解决依赖关系完成 依赖关系解决 ===========================================================================================================
Package 架构 版本 源 大小
===========================================================================================================
正在安装:
openssl x86_64 :1.0.2k-.el7_6. updates k 事务概要
===========================================================================================================
安装 软件包 总下载量: k
安装大小: k
Is this ok [y/d/N]

恢复正常

linux误卸载openssl后的恢复的更多相关文章

  1. 卸载openssl后yum无法使用,ssh无法连接的解决办法

    一,安装nginx时,提示openssl版本问题,用yum update openssl 发现还是不行,于是rpm -e 卸载了openssl 此时,才发现yum不能用了,然后想上传个tar包时又出现 ...

  2. Linux下误删除后的恢复操作(ext3/ext4)

    Linux是作为一个多用户.多任务的操作系统,文件一旦被删除是难以恢复的.尽管删除命令只是在文件节点中作删除标记,并不真正清除文件内容,但是其他用户和一些有写盘动作的进程会很快覆盖这些数据.在日常工程 ...

  3. MySQL误操作删除后,怎么恢复数据?

    MySQL误操作删除后,怎么恢复数据?登陆查数据库mysql> select * from abc.stad;+----+-----------+| id | name |+----+----- ...

  4. was控制台误禁用后的恢复启用办法

    websphere是可以配置禁用控制台的,下面以was6.1.单profile.https控制台为例介绍在(误)禁用控制台后如何恢复启用控制台. 1. 禁用控制台 WCInboundAdmin--控制 ...

  5. linux环境变量设置错误后的恢复方法(转)

    原文: http://blog.csdn.net/hoholook/article/details/2793447 linux环境变量设置错误后的恢复方法 中国自学编程网收集整理  发布日期:2008 ...

  6. win7,ubuntu双系统——重装win7后如何恢复ubuntu引导

    磁盘分区——windows 7自带分区工具实现 磁盘分区——PQ硬盘分区魔术师 win7,ubuntu双系统的安装——正式安装 win7,ubuntu双系统的安装——卸载ubuntu 讲述了我的  w ...

  7. Linux内核卸载和禁止更新

    注意:对于可以用好几条命令实现的,第一条命令已经验证,其他的命令参考自网上,没有进行验证. 查看Linux系统内核的命令有下面几条 dpkg --get-selections | grep linux ...

  8. Linux配置完iptables后,重启失效的解决方案

    Linux配置完iptables后,重启失效的解决方案 因为只有root用户才可访问1024以下的端口,非root用户登陆是不能启用80端口的.web service 往往启动1024以上的端口,并通 ...

  9. Oracle误删除表数据后的恢复具体解释

    Oracle误删除表数据后的恢复具体解释 測试环境: SYSTEM:IBM AIX 5L                         Oracle Version:10gR2 1. undo_re ...

随机推荐

  1. Gson解析list类型的json串

    Gson gson = new Gson(); Type type = new TypeToken<List<Object>>() {}.getType(); List< ...

  2. Arrays类与Collections类

    java.util.Arrays类包含一个静态的工厂,允许数组被视为列表.以下是关于数组的要点: 这个类包含了各种方法来操作数组(比如排序和搜索). 在这个类中的方法抛出NullPointerExce ...

  3. VS2017 中安装SVN

    VS2017 中安装SVN   1.下载:SVN For Vs2017 2.安装: 先关闭VS2017,找到下载文件,直接双击,安装. 3.启用插件 打开Vs2017,直接可用.

  4. python学习笔记:(十四)面向对象

    1.类(class): 用来描述具有相同的属性和方法的对象的集合.它定义了该集合中每个对象所共有的属性和方法 2.类变量: 类变量在整个实例化的对象中是公用的.类变量定义在类中且在函数体之外.类变量通 ...

  5. 使用canvas实现对图片的批量打码

    最近有个需求,利用h5的canvas对图片一些涉及个人隐私的地方进行打码再上传,而且最好能实现批量打码.意思是在一张图片上对哪些地方做了打码,后续的所有图片都在同样的地方也可以自动打上码,不用人工一张 ...

  6. iOS发版出现“No iTunes Connect access for the team”的问题的解决方式

    要发个新版本,结果发现,老是提示我“No iTunes Connect access for the team”,出现以下错误:   图1 错误提示: No accounts with iTunes ...

  7. python3 selenuim PC端使用chrome模拟手机进行H5自动化

    情况说明:初次在做PC端使用chrome进行H5自动化测试时,以为和app端自动化一样使用click()就可以对按钮进行点击,找了好几天也没有找到解决方法,有些人说是工程问题,有些人是使用微信进行H5 ...

  8. v-if 和v-show的区别

    在切换 v-if 块时,Vue.js 有一个局部编译/卸载过程,因为 v-if 之中的模板也可能包括数据绑定或子组件.v-if 是真实的条件渲染,因为它会确保条件块在切换当中合适地销毁与重建条件块内的 ...

  9. 使用Spring Initializr初始化SpringBoot项目

    虽然SpringBoot CLI消除了不少设置工作,但如果你更倾向于传统的Java项目结构,那你应该看看Spring Initializr. Spring Initializr从本质上来说就是一个we ...

  10. jmeter对websocket进行压测

    参考文档:https://blog.csdn.net/weixin_39430584/article/details/81508451 ①脚本调通 ②添加并发量和持续时间 ③看服务器指标