In the past, I never had to use ssh-agent
and everything worked fine.
But I noticed, on GitHub, it is asking people to use ssh-agent
, even if we don't use it, it seemed fine. So I just ignore that lengthy part usually for the ssh-agent
and ssh-add
.
But for a few days I was able to log onto Bluehost, but yesterday day I added a new pair of public and private key to my MacBook Air M1, and now the log in that used to work becomes:
Received disconnect from 162.241.123.123 port 22:2: Too many authentication failures for mike123
Disconnected from 162.241.123.123 port 22
without even asking for a password. But it was strange why when it let me log in, it asked me for password, when I thought the whole idea of ssh is not requiring password.
But today, it does not even ask me for password but spit out the message above.
However, my MacBook Pro was able to log in, even though it is asking for a password.
The Bluehost tech support was saying, I should paste my private key to their Bluehost SSH panel. But I thought we should never give out our private key.
So must we use ssh-agent
now? What might be the issue of "Too many authentication failures for _____" and how is it solved?
P.S. Aftermath: I did follow the steps in the Github docs above and used ssh-agent
and ssh-add
, and created the file ~/.ssh/config
. The fact that ssh-keygen
did not create ~/.ssh/config
might suggest ~/.ssh/config
is not a usual practice, but after I did the above steps, then I was able to be asked a password and be able to log in again to Bluehost. Why it still is asking for a password, I am not sure, but at least it is letting me log in.
id_dsa
file that can be copied and added, and is accessible via cPanel. If you can access it on one machine, it's pretty much a given that it's there. You're correct about giving out your private key—doing so pretty much negates the purpose of having the public/private key arrangement to begin with.-d
flag and add it to your question so we'll have more details?