Support Questions
Find answers, ask questions, and share your expertise

host registration error in ambari wiz while install HDP 2.4 using ambari 2.2

Rising Star

Hi All,

I got below error mes while try to registered host in ambari 2.2

i have install ssh and copy the ssh private key in Host Registration Information

i have copy the public key to >> authorized_key

cat /root/.ssh/ >>authorized_keys

chmod 700 -R /root/.ssh

chmod 600 /root/.ssh/authorized_keys

Creating target directory... ========================== Command start time 2017-01-31 11:03:04 Permission denied (publickey,password). SSH command execution finished host=ubuntu, exitcode=255 Command end time 2017-01-31 11:03:04 ERROR: Bootstrap of host ubuntu fails because previous action finished with non-zero exit code (255) ERROR MESSAGE: Permission denied (publickey,password). STDOUT: Permission denied (publickey,password).


Super Mentor


Here it would be best to run the following commands and then verify whether you are able to do Password less ssh without any issue.

Run the following command from ambari-server host:

ssh-copy-id  -i /root/.ssh/  localhost
ssh-copy-id  -i /root/.ssh/
ssh-copy-id  -i /root/.ssh/
ssh-copy-id  -i /root/.ssh/
ssh-copy-id  -i /root/.ssh/



Have you tried to do ssh manually from ambari server to other host?

Rising Star

@Ashnee Sharma

I wanted to install ambari-sever and agent on single machine(standalone).

I have try ssh root@localhost and its working fine..

Super Mentor


1. Can you please share the "/etc/ssh/sshd_config" file content here ?

2. Checking the "PasswordAuthentication" and "ChallengeResponseAuthentication" will be good.

3. Is your ambari running as "root" user or some other user?

- A Quick Workaround will be to install the Agent Manually as :

Rising Star

@Jay SenSharma

i am using root user for installing ambari..and i am using only one system for both ambari server and client..


Delete the .ssh file. And create key again, dont change the permission of folder and create authorized_keys file inside and add public key. Then try to reinstall again.

Also please check your hostname and /etc/hosts file, check iptable and selinux.

is issue is resolved?

Rising Star

HI@Ashnee Sharma

Not yet it is resolved, i was stuck here, i have try all possibilities

1) i have deleted the .ssh file and created again

2) i have disable the iptable

3) i have selinux is disable(not installed)

is there any other option to install with ssh or any suggestion ?

Please check your /etc/hosts file. As well as ntp and permission of .ssh folder and all files which is under the .ssh.

One query are you installing the hdp with root user?



I noticed in your snippet above chmod 700 -R /root/.ssh instead of

chmod 700 ~/.ssh
chmod 600 ~/.ssh/authorized_keys

Is your installation a single or multi node if the later then you MUST copy the authorized_keys form the Ambari host aka Management server to the other nodes in the /root/.ssh/ directory, It seems you are on Ubuntu please find the correct syntax.

Expert Contributor

Please check the permission of your public and private keys i.e and id_rsa.

; ;