Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The agent has no identities. #5

Closed
tremby opened this issue May 22, 2013 · 2 comments
Closed

The agent has no identities. #5

tremby opened this issue May 22, 2013 · 2 comments

Comments

@tremby
Copy link

tremby commented May 22, 2013

Similar to #3, I believe.

I had a similar issue -- the script exited with code 1 with no error, and on inspecting authorized_keys on the remote the string The agent has no identities. had been added. This was the output of ssh-add -L, even though I did have an id_rsa file. The solution for me was to run ssh-add alone, which gave some encouraging output, and after that ssh-add -L gives the expected output and so running ssh-copy-id again worked.

I'm surprised by that because I've never had to run that before.

Perhaps ssh-add could be run automatically if ssh-add -L returns an error code (I didn't check if it did, but presumably it does in this case), or at least notify the user that they may want to run it. And obviously don't add something to the remote's authorized_keys if it's not actually a key!

@beautifulcode
Copy link
Owner

Hi there. I merged #3's pull-request in. Can you see if this fixes things for you?

@tremby
Copy link
Author

tremby commented Jun 7, 2013

I had a new server to log in to today. I tried ssh-add -L before doing anything else and got The agent has no identities..

I ran ssh-copyid with the hostname, accepted the host's key and got exit code 1. I then tried to log in and it asked for my password. I entered it and logged in. Printing out authorized_keys shows a garbled line like in #6.

Given that the line The agent has no identities is not in the authorized_keys file, this issue is fixed but obviously the other still exists.

@tremby tremby closed this as completed Jun 7, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants