ubuntu ssh_config 和 sshd_config的区别


可能你安装好ubuntu后想通过SSH连接,但是怎么会连接不上?在ssh_config 里面也配置了啊,其实这个文件是用来配置的客户端的(Server自己做客户端连接别的Server的时候),搜索到一篇外文介绍

ssh_config: configuration file for the ssh client on the host machine you are running. For example, if you want to ssh to another remote host machine, you use a SSH client. Every settings for this SSH client will be using ssh_config, such as port number, protocol version and encryption/MAC algorithms.

sshd_config: configuration file for the sshd daemon (the program that listens to any incoming connection request to the ssh port) on the host machine. That is to say, if someone wants to connect to your host machine via SSH, their SSH client settings must match your sshd_config settings in order to communicate with you, such as port number, version and so on.

所以接下来你得看sshd_config 存在吗?不存在就安装

sudo apt-get install openssh-server

sudo service ssh start

ps –ef | grep ssh


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM