windows 通过SSH 访问 Ubuntu 16.04

本文介绍了如何在Windows上通过SSH连接到Ubuntu 16.04系统。首先确保安装了openssh-server和client,然后启动SSH服务,并检查进程。如果遇到登录问题,可能需要修改ssh配置文件PermitRootLogin为yes,并添加加密算法。重启SSH服务后,可以尝试使用SecureCRT等工具进行远程登录。
摘要由CSDN通过智能技术生成

windows 通过SSH 访问 Ubuntu 16.04

1、首先确保已安装ssh,若未安装通过以下指令进行修改
(在root用户下操作)
apt-get install openssh-server openssh-client
apt-get install ssh

2、启动 ssh服务:/etc/init.d/ssh start
再查看进程 :ps -e | grep ssh,查看sshd(虚拟机作为服务器)这个进程是否运行,ssh-agent(虚拟机作为客户端)
若无这个进程sshd,可能是配置文件出了问题,建议将ssh及其配置文件全部卸载重新安装,若了解配置文件直接修改配置文件也可。
清除式卸载:apt-get purge openssh-server
apt-get purge openssh-client
apt-get purge ssh
(清除配置文件并卸载ssh)

3、使用secure-CRT通过ssh协议远程登陆访问root用户,若输入正确的密码结果显示密码错误无法登陆;
则需修改ssh的配置文件。
(1)
vim /etc/ssh/sshd_config

将PermitRootLogin修改成yes

在文件最后面添加:
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

  • (2)
    重启SSH服务:service ssh restart
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

小嵌同学

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值