In Ubuntu 16.04 I executed:
eval $(ssh-agent) && ssh-add
I got:
Agent pid 3361
I then SSH tunneled into my VPS successfully, after inserting my passphrase.
The problem:
Well, it's not that much of a "problem", but:
I went back to my local session with exit, and when I tried to login to my VPS again, I had to reenter my passphrase...
My question:
Why would I be asked to enter the passphrase again?
I didn't close the current session and did eval $(ssh-agent) && ssh-add, before tunneling. So, why the system won't "remember" it?
ssh-add -lbefore and after the working SSH connection to make sure the agent still holds the key after the first exit. Then try usingssh -vv(two v's) on your second attempt to connect so that the client will show you all the keys it's trying. – Steven K Feb 06 '17 at 04:16