zoukankan      html  css  js  c++  java
  • ubuntu hadoop 环境创建ssh无密码登录 localhost

    这几天在自己的ubuntu机器上,研究sector/sphere,突然发现我原来在公司配置ssh无密码登录的办法无效,后来搜索后知道了原因,现将ubuntu上设置ssh无密码登录的步骤列出来:

    步骤
    1.创建密钥

    ~/.ssh$ ssh-keygen -t rsa

    Generating public/private rsa key pair.

    Enter passphrase (empty for no passphrase): (忽略)

    Enter same passphrase again: (忽略)

    Your identification has been saved in /.ssh/id_rsa.

    Your public key has been saved in /.ssh/id_rsa.pub.

    2.添加公密到信任列表

    ~/.ssh$ cat 192.168.1.110 >> authorized_keys

    ~/.ssh$

    3.启动ssh-agent (以前没有做过的步骤)
    如果ssh localhost返回这样的提示

    Agent admitted failure to sign using the key
    ps -aux|grep agent查看有无ssh-agent有无运行,若没有

    ~/.ssh$ ssh-agent

    4.添加id_rsa到ssh-agent

    ~/.ssh$ ssh-add id_rsa
  • 相关阅读:
    第二阶段冲刺(一)
    第一冲刺阶段博客检查汇总
    整改方案
    意见
    站立会议(九)
    站立会议八
    我爱淘二次冲刺阶段1
    我爱淘冲刺阶段7
    我爱淘冲刺阶段6
    我爱淘冲刺阶段5
  • 原文地址:https://www.cnblogs.com/licheng/p/2240693.html
Copyright © 2011-2022 走看看