CentOS   发布时间:2022-04-02  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了CentOS7.2升级openSSH为7.5P1无法登录的处理过程大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。

概述

1.开始安装高版本的的openSSH的时候,系统自带的没有卸载,重启sshd进程,sshd -h查看也是后面安装的高版本,但是telnet 127.0.0.1 22发现仍然还是老版本的信息,这时才发现应该时没有安装成功 2.于是,卸载重新安装,再次重启,这次telnet 127.0.0.1 22发现版本已经变成7.5的了 3.但是这时,ssh无法登陆,告诉/etc/bash: Permission

1.开始安装高版本的的openSSH的时候,系统自带的没有卸载,重启sshd进程,sshd -h查看也是后面安装的高版本,但是telnet 127.0.0.1 22发现仍然还是老版本的信息,这时才发现应该时没有安装成功
2.于是,卸载重新安装,再次重启,这次telnet 127.0.0.1 22发现版本已经变成7.5的了
3.但是这时,ssh无法登陆,告诉/etc/bash: Permission denied
4.这时setenforce 0,倒是能正常ssh登陆,不相信必须得关闭selinux
5.于是setenforce 1,ssh登陆,查看/var/log/message,发现有如下信息:
Feb 1 22:28:57 localhost setroubleshoot: SELinux is prevenTing /usr/local/sbin/sshd from using the transition access on a process. For complete SELinux messages. run sealert -l 6ca7e4db-d52f-41a3-8199-505f7a77a6c9
Feb 1 22:28:57 localhost python: SELinux is prevenTing /usr/local/sbin/sshd from using the transition access on a process.#012#012* Plugin catchall (100. confidencE) suggests **#012#012If you believe that sshd should be allowed transition access on processes labeled unconfined_t by default.#012Then you should report this as a bug.#012You can generate a local policy module to allow this access.#012Do#012allow this access for Now by execuTing:#012# ausearch -c 'sshd' --raw | audit2allow -M my-sshd#012# semodule -i my-sshd.pp#012

6.里面已经说解决方法,于是运行下面两个命令:ausearch -c 'sshd' --raw | audit2allow -M my-sshdsemodule -i my-sshd.pp搞定

大佬总结

以上是大佬教程为你收集整理的CentOS7.2升级openSSH为7.5P1无法登录的处理过程全部内容,希望文章能够帮你解决CentOS7.2升级openSSH为7.5P1无法登录的处理过程所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。