Hadoop : Permission denied (publickey,password, keyboard-interactive)

Viewed 3654

While installing Hadoop I got many errors but this one just doesn't go. No matter what I do, it keeps popping again and again. As soon as I am starting Hadoop by the command ./start-all.sh, I get the error:

localhost: rajneeshsahai@localhost: Permission denied (publickey,password,keyboard-interactive)

Error logs:

Starting namenodes on [localhost]
localhost: rajneeshsahai@localhost: Permission denied (publickey,password,keyboard-interactive).

Starting datanodes
localhost: rajneeshsahai@localhost: Permission denied (publickey,password,keyboard-interactive).

Starting secondary namenodes [MacBook-Air.local]
MacBook-Air.local: rajneeshsahai@macbook-air.local: Permission denied (publickey,password,keyboard-interactive).

2020-05-29 18:42:06,106 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable

Starting resourcemanager
resourcemanager is running as process 2937.  Stop it first.

Starting nodemanagers
localhost: rajneeshsahai@localhost: Permission denied (publickey,password,keyboard-interactive).

I already tried the following things:

  1. ssh-keygen -t rsa

    cat ~/.ssh/id-rsa.pub >> ~/.ssh/authorized_keys

    chmod 600 ~/.ssh/authorized_keys

    I think repeating this process has created multiple keys in my system.

  2. sudo passwd

  3. Configured /etc/ssh/sshd_config

    (i) Changed PermitRootLogin prohibit-password to PermitRootLogin yes

    (ii) Changed PasswordAuthentication no to PasswordAuthentication yes

    I do have one doubt: Do I have to remove the hash tag (#) from the lines?

I am using macOS Catalina.

2 Answers

You can try the following:

$ ssh-keygen -t rsa -P '' -f ~/.ssh/id_rsa
$ cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
$ chmod 0600 ~/.ssh/authorized_keys
Related