1

My ~/.profile contains the following:

SSHAGENT=/usr/bin/ssh-agent SSHAGENTARGS="-s" if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]; then eval `$SSHAGENT $SSHAGENTARGS` eval `keychain --eval id_rsa git-key` fi 

As expected, I am prompted for a password on login and ssh-agent is started. However, it ends up only having the key id_rsa (verified via "ssh-add -l"). It doesn't load git-key into ssh-agent even though it and id_rsa have the same password. If I then run:

eval `keychain --eval id_rsa git-key` 

from the command line git-key is also loaded and ssh-agent now has both keys.

My question is, why is only one of the two keys getting loaded on login?

1 Answer 1

0

Doh! I use git to keep my .profile and other configs synced between several machines. My latest git merge didn't merge the way I expected so I had two different lines with calls to keychain only one of which was getting executed.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.