When working remotely, one is known to sometime connect to a machine (within the vpn’d network) as a jump box. Unfortunately, it doesn’t seem to cache the ssh keys properly. Thus, they should be stopped and restarted:
ps -ef |grep "[s]sh-agent -s" | awk '{print "kill " $2}' |sh
eval ssh-agent -s
ssh-add ~/.ssh/id_rsa
Of course, if you are using a non-standard keyname, put the correct keyname in the last step.
Category: Linux