您的位置:首页 > 运维架构 > Shell

使用XShell工具密钥认证登录Linux系统

2016-10-30 11:38 405 查看
点击Xshell菜单栏的工具,选择新建用户密钥生成向导,进行密钥对生成操作。















到Linux来,禁用密码
root@iZt4nebncsy4e2ognhpgcnZ:~# vim /etc/ssh/sshd_config
改为:
PasswordAuthentication no

重启ssh
root@iZt4nebncsy4e2ognhpgcnZ:~# /etc/init.d/ssh restart

配置公钥:
root@Debian:~# cd
root@Debian:~# mkdir .ssh
root@Debian:~# vim .ssh/authorized_keys
把刚才的win机器的pubkey粘贴到这里.

打开Xhell
直接登录
Xshell:\> ssh root@47.88.***.***



登录成功:
Welcome to aliyun Elastic Compute Service!

Last login: Sun Oct 30 11:29:31 2016 from 115.199.111.13
root@Debian:~#

接下来才能安心干活.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  工具 使用 XShell