-1

Logging into my work station over SSH, I notice that none of my aliases work. Sure enough:

$ alias
$ source ~/.bashrc
Could not open a connection to your authentication agent.

So I googled the error message, but all the information that I could find relate to users of Cygwin or Putty logging into their Linux machines. In my case, I'm logging in from one Linux machine (Kubuntu 12.10) to another (Kubuntu 13.04). Also, I can actually log in and run commands. I just cannot source ~/.bashrc!

I ask here instead of on unix.SE as this seems more of a "connecting to remote machine properly" issue, which is very relevant to servers. As per the Help Center this seems on-topic. If mods feel that unix.SE is more appropriate, then I have no problems moving the question there.

Note that I tried to source ~/.bashrc because I had suspected that the aliases were not defined due to .bashrc not being read on SSH logins.

dotancohen
  • 2,720

2 Answers2

1

This error message suggests that you have issues with connections to the SSH agent from inside the ~/.bashrc. Remove any calls to ssh-add from it and test again. If that fixes your problem, you can hunt for the root cause of the agent problem.

Sven
  • 100,763
0

I'm not sure what you're trying to do with 'source'.

Add aliases to your ~/.bashrc and restart your session for them to work. If they don't, then provide the error symptoms.

Peter
  • 1,460