linux知识点

[ssh Secure连接服务器错误]Server respon

2019-05-07  本文已影响0人  测试_机器猫

1、检查ssh的服务是否正常,如果不正常,或者报错,卸载重新安装

卸载:sudo apt-get remove openssh-server

安装:sudo apt-get install openssh-server

查看服务状态:sudo service ssh status

2、sudo vim /etc/ssh/sshd_config 通过命令在配置文件中增加如下内容:

Ciphers aes128-cbc,aes192-cbc,aes256-cbc,aes128-ctr,aes192-ctr,aes256-ctr,3des-cbc,arcfour128,arcfour256,arcfour,blowfish-cbc,cast128-cbc

MACs hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160,hmac-sha1-96,hmac-md5-96

KexAlgorithms diffie-hellman-group1-sha1,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group1-sha1,curve25519-sha256@libssh.org

3、重启sshd服务,输入如下命令:

sudo /etc/init.d/ssh restart

4、接着用工具连接就行了

上一篇下一篇

猜你喜欢

热点阅读