OK, I'm having a problem settings up SVN+SSH.
I have SVN running on a Linux server and trying to connect from a Mac laptop running Snow Leopard. XCode tries to connect, but gives the message "Error 210002, network connection closed unexpectedly."
Nothing online seems to explain. I connect using xcode with HTTP and it works correctly for all repositories.
Here's my SVN vesrion:
svn, version 1.5.4 (r33841)
compiled Aug 7 2009, 01:44:11
Copyright (C) 2000-2008 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).
The following repository access (RA) modules are available:
* ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
- handles 'http' scheme
- handles 'https' scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
- with Cyrus SASL authentication
- handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
- handles 'file' scheme
I currently have it set up to use http, which works without problems.
http://[email protected]/svn/project
I can ssh to the server using username and password, and run commands such as
svn list file:///home/svn/project
and I get a listing of the contents of that project. So, I don't think it's a permissions problem.
Files on server are at /home/svn/project.
I'm trying to get this to work in XCode. Doesn't work using the path as /home/svn/project or just /svn/project as works in http.
But, from the laptop, the following command does list info as expected:
svn list svn+ssh://[email protected]/home/svn/project
[email protected]'s password:
branches
tags
trunk
Killed by signal 15.
The program svnserve isn't running, but the user I'm logging in with has the ability to run it. If I do start it in foreground mode, it doesn't seem to change anything.
Any ideas what I'm missing. Would love to be able to run svn+ssh and turn off http access.
Cheers!
EDIT
For some more information, I found that it's only one repository. All other repositories on the server seem to be working correctly with SVN+SSH.
It seems to be an XCode bug, but I don't know for sure. It's something about how XCode reads SSH connection information that may be cached in the computer.
To suppress "killed by signal 15" messages please set SVN_SSH="ssh -q"
as mentioned here.
That 'Killed by signal 15' is a clue that something is not quite right even with your command line usage. I remember fixing the same issue, but don't remember the exact cause. I think it had to do with how I was handling my non-standard ssh port and having a different username on my local computer and the remote server.
Does your svn host have a non-standard ssh port and/or different username? I switched from using a SVN_SSH variable to set the port to putting a proper entry in my .ssh/config file that set both the username and port for the ssh connection.
Host example.com
User username
Port port
I'm not sure whether xcode respects your .ssh/config though.
Does your server have a firewall, and if so, does it limit the number of SSH connection attempts, such as by the method described here? We were experiencing the exact same problem of having the connection dropped for svn checkout
, but not for svn ls
, over svn+ssh://
. We adjusted the connection settings on the firewall to be more lenient, allowing more connections per minute, and this instantly cleared our problems. It seems that SVN is very aggressive in initiating connections during certain operations, and less so for others.
None of solutions given here worked with svn+ssh
, but I could connect and checkout via https
:
$ svn checkout --username myusername https://scm.gforge.inria.fr/svn/concha
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With