Linux远程秘钥登录方式
2016-01-18 14:27
513 查看
一、putty
1、puttygen同时生成一个公钥和一个私钥(私钥可以设置密码)
2、公钥复制到/root/.ssh/authorized_keys(权限改为600),目录/root/.ssh改为700,私钥文件保存到本地;
3、关闭防火墙selinux和iptables,selinux 临时关闭 setenforce 0,永久关闭 /etc/seliinux/config 中改selinux=disabled
临时清楚iptables:iptables -F ,永久关闭iptables,上述基础之上service iptables save
4、putty连接时,Connection/SSH/Auth 注意秘钥(私钥)的选择。
二、xshell
1、首先利用xshell的自带工具生成秘钥,主要复制公钥;
2、公钥复制到/root/.ssh./authorized_keys(权限改为600),目录/root/.ssh改为700,私钥文件保存到本地;
3、关闭防火墙selinux和iptables,selinux 临时关闭 setenforce 0,永久关闭 /etc/seliinux/config 中改selinux=disabled
临时清楚iptables:iptables -F ,永久关闭iptables,上述基础之上service iptables save
4、登录时候“用户身份验证-方法-public key”
1、puttygen同时生成一个公钥和一个私钥(私钥可以设置密码)
2、公钥复制到/root/.ssh/authorized_keys(权限改为600),目录/root/.ssh改为700,私钥文件保存到本地;
3、关闭防火墙selinux和iptables,selinux 临时关闭 setenforce 0,永久关闭 /etc/seliinux/config 中改selinux=disabled
临时清楚iptables:iptables -F ,永久关闭iptables,上述基础之上service iptables save
4、putty连接时,Connection/SSH/Auth 注意秘钥(私钥)的选择。
二、xshell
1、首先利用xshell的自带工具生成秘钥,主要复制公钥;
2、公钥复制到/root/.ssh./authorized_keys(权限改为600),目录/root/.ssh改为700,私钥文件保存到本地;
3、关闭防火墙selinux和iptables,selinux 临时关闭 setenforce 0,永久关闭 /etc/seliinux/config 中改selinux=disabled
临时清楚iptables:iptables -F ,永久关闭iptables,上述基础之上service iptables save
4、登录时候“用户身份验证-方法-public key”
相关文章推荐
- Linux socket 初步
- Linux Kernel 4.0 RC5 发布!
- linux lsof详解
- linux 文件权限
- Linux 执行数学运算
- 10 篇对初学者和专家都有用的 Linux 命令教程
- Linux 与 Windows 对UNICODE 的处理方式
- Ubuntu12.04下QQ完美走起啊!走起啊!有木有啊!
- 解決Linux下Android开发真机调试设备不被识别问题
- 运维入门
- 运维提升
- Linux 自检和 SystemTap
- Ubuntu Linux使用体验
- c语言实现hashmap(转载)
- Linux 信号signal处理机制
- linux下mysql添加用户
- Scientific Linux 5.5 图形安装教程
- Linux 下无损图片压缩小工具介绍