Hope you are doing well


Please follow the steps given below:


1) Create the ssh key in all the nodes. [For both nodes]


ssh-keygen –t rsa




Don’t give any path at the Enter file in which to save the key and don’t give any passphrase,


Press enter button only.


Do the ssh key generation process in all the nodes.


Once ssh key is generated you will get the public key and private key.


2) Copy/Append the public key to the authorized_keys file of the local machine [ For both nodes]


cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys




3) Copy the Namenode public key to all the nodes using SCP command


scp ~/.ssh/id_rsa.pub edureka@<IP address of node>:/home/edureka/.ssh/authorized_keys

 

Name Node to Datanode1 (Data node 1 IP address is 192.168.1.71)




4) Change the Permission to authorized_keys. (Do the step in all the nodes)

 

chmod 755 ~/.ssh/authorized_keys


 


5) Disable the firewall in both nodes

 

sudo service iptables stop

'
sudo chkconfig iptables off


6) Please restart the sshd service in each node and try to ssh login from namenode to each node.


1) To restart sshd service :


sudo service sshd restart


2) For ssh login to other node from namenode:


ssh hostname_of_destination_node


or,


ssh ip_of_destination_node


I think this will resolve the query.


Please let me know if the issue still persists.


Feel free to contact us in case you have any other query. 

 

Kindly share your feedback by clicking on either of the smiley's.