ssh免密码登陆设置
2015-04-19 16:29
176 查看
服务器端
CentOS 6.5下编辑/etc/ssh/sshd_config
MacOSx下编辑/etc/sshd_config
然后重启sshd服务
PS.CentOS下完成以上步骤以后若出现拒绝访问的情况,还需要修改SELinux设置或直接关闭SELinux(修改 /etc/selinux/config,置SELINUX=disabled,重启电脑)
客户端
然后将客户端~/.ssh/id_rsa.pub文件复制到服务器上,然后在服务器上进行如下操作
CentOS 6.5下编辑/etc/ssh/sshd_config
MacOSx下编辑/etc/sshd_config
#开启公钥验证 RSAAuthentication yes PubkeyAuthentication yes AuthorizedKeysFile .ssh/authorized_keys #关闭密码验证 PasswordAuthentication no
然后重启sshd服务
PS.CentOS下完成以上步骤以后若出现拒绝访问的情况,还需要修改SELinux设置或直接关闭SELinux(修改 /etc/selinux/config,置SELINUX=disabled,重启电脑)
客户端
ssh-keygen -t rsa -P ''
然后将客户端~/.ssh/id_rsa.pub文件复制到服务器上,然后在服务器上进行如下操作
cat id_rsa.pub >> ~/.ssh/authorized_keys
相关文章推荐
- ssh免密码登陆设置时Authentication refused: bad ownership or modes错误解决方法
- 设置centos下SSH无密码登陆
- 设置Linux中的ssh无密码登陆
- hadoop设置ssh免密码登陆
- mac电脑设置 ssh localhost免密码登陆 hadoop需要
- ssh 无密码登陆设置
- 一路Hadoop-- 7、如何设置SSH免密码登陆
- ubuntu14.04设置SSH免密码登陆
- linux下设置SSH无密码登陆
- SSH免密码登陆设置
- 设置ssh登陆的时候不用输入密码的方法:
- 批量设置ssh无密码登陆脚本
- ssh 非交互免输入密码自动登陆设置
- 设置SSH自动登陆(免密码,用户名)
- putty中设置ssh无密码登陆
- git设置远程仓库关于多用户ssh无密码登陆问题
- hadoop安装过程中ubuntu系统ssh免密码登陆设置
- mac下 ssh免密码登陆设置
- ssh 设置免密码登陆和快捷设置
- centos设置ssh免密码登陆