ubuntu18.04安装ssh服务

原文链接:https://www.cnblogs.com/tansuoxinweilai/p/11617797.html

在ubuntu 18.04.03 server 版系统亲测成功,以下图文还是原文博主的材料。(最后远程连接测试的时候,我图方便就用了putty哈哈哈)

一、安装openssh-service

命令: sudo apt install openssh-server

二、启动ssh服务

命令: sudo service ssh start
检查是否启动成功: ps -aux | grep ssh
如果出现下方标黄部分的sshd 就说明启动成功

三、下载openssh-client

命令: sudo apt install openssh-client

四、使用xshell进行远程登录

命令:ssh user@ip
user: ubuntu用户名
ip:通过ifconfig获取的ip地址
登录成功出现如下界面

五、xshell连接

查看服务器ip
ifconfig
打开xshell,配置如下:

主机就是服务器内网ip,端口22为默认的端口也可以通过配置进行修改

用户名和密码为ubuntu的用户名和密码

原文地址:https://www.cnblogs.com/huashanqingzhu/p/11889038.html