Forum: Rails deployment can't do cap setup

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Ivan S. (Guest)
on 2007-06-06 22:51
This is the first time I'm trying out capistrano, so I'm sure there's
something I simple I'm missng.

I can ssh to the server using a public rsa key just fine. The username
is the same on my laptop as on the server.

ivan:10:40 AM:writr> cap setup
  * executing task setup
  * executing "umask 02 &&\n    mkdir -p /var/www/
/var/www/ /var/www/
/var/www/ &&\n    mkdir -p
/var/www/ &&\n    mkdir -p
    servers: [""]
`initialize': No such file or directory - /tmp/501/SSHKeychain.socket
         ... 13 levels...
        from /usr/local/bin/cap:18

Thanks for any help!
Ivan S. (Guest)
on 2007-06-07 01:00
I also tried deleting my keys, on the laptop and the server, and then
running cap setup. It seems to be re-adding a ssh-dss key from somewhere
into my local known_hosts. Not sure why
Ivan S. (Guest)
on 2007-06-07 20:39
Well, I found the solution and hopefully others will find this thread if
they are stuck too.

thanks to

"You can temporarily fix this in the console by typing: unset

so it works, but I don't understand why.
digitalronin (Guest)
on 2007-06-08 13:45
(Received via mailing list)
> "You can temporarily fix this in the console by typing: unset
> so it works, but I don't understand why.

I'm sure someone will correct me if I'm wrong, but my guess would be
that at some point, you had an ssh-agent running. ssh-agent is a
process which holds your private keys in memory, so that you
authenticate them once and then you don't have to type your ssh
passphrase again (until the next time you reboot, or close down the
ssh-agent). See 'man ssh-agent' for details.

ssh-agent creates an SSH_AUTH_SOCK environment variable, which holds
the socket number that any ssh processes can use to communicate with
the ssh-agent. It sounds as if you had an ssh-agent running at some
point, but that it shut down for some reason. So, there was a left-
over SSH_AUTH_SOCK environment variable, but no agent listening on
that socket.

So, when cap tries to use ssh to connect to your server, ssh tries to
talk to an ssh-agent that isn't there, and it fails. By unsetting
SSH_AUTH_SOCK, ssh processes will not try to connect to the missing
agent, and will fall back to negotiating the connection themselves,
which works fine.

Of course, I could be talking utter rubbish!


This topic is locked and can not be replied to.