Tencent cloud server centos use (a) --- install ssh server

First, the purchase of Tencent cloud server connection using xshell server prompts the server rejects the connection, you need to install ssh in the server service
1, log in Tencent cloud server console
using the command to view the installation rpm -qa | grep openssh, the following installation instructions appear the installation is complete, if not then install the missing software

rpm -qa | grep openssh

2, install missing software

sudo yum install openssh*

3, start ssh service

service sshd start

4, start using xshell after their return error: Connection closed by foreign host

5, the SSH server does not keep alive interval, setting is as follows:

vim /etc/ssh/sshd_config
# 添加或者注释下面两行
ClientAliveInterval 60
ClientAliveCountMax 3
#重启服务器
/etc/init.d/ssh restart

6, you can use this link to the server xshell

Published 27 original articles · won praise 12 · views 50000 +

Guess you like

Origin blog.csdn.net/baidu_38226233/article/details/103597985