5.2. Set Up Password-less SSH

To have Ambari Server automatically install Ambari Agents in all your cluster hosts, you must set up password-less SSH connections between the main installation (Ambari Server) host and all other machines. The Ambari Server host acts as the client and uses the key-pair to access the other hosts in the cluster to install the Ambari Agent.

[Note]Note

You can choose to install the Agents on each cluster host manually. In this case you do not need to setup SSH. See Appendix: Installing Ambari Agents Manually for more information.

  1. Generate public and private SSH keys on the Ambari Server host

    ssh-keygen
  2. Copy the SSH Public Key (id_rsa.pub) to the root account on your target hosts. Depending on your version of SSH, you may need to set permissions on your .ssh directory (to 700) and the authorized_keys file in that directory (to 640).

    .ssh/id_rsa
    .ssh/id_rsa.pub
  3. Add the SSH Public Key to the authorized_keys file.

    cat id_rsa.pub >> authorized_keys
  4. From the Ambari Server, make sure you can connect to each host in the cluster using SSH.

    ssh root@{remote.target.host}

    You may see this warning. This happens on your first connection and is normal.

    Are you sure you want to continue connecting (yes/no)?
  5. Retain a copy of the SSH Private Key on the machine from which you will run the web-based Ambari Install Wizard.


loading table of contents...