Monday, September 28, 2009

TortoiseSVN weirdness

I had tremendous difficulties today trying to connect to a svn+ssh repository on a Solaris server using TortoiseSVN on a Windows client. I kept getting error messages of the form "network connection closed unexpectedly" with no explanation. Fortunately, I was able to find a workaround (see below).

I think the problem was bash on the server: every non-interactive ssh login was printing error messages to stderr, and for whatever reason TortoisePlink (the ssh client included with Tortoise) could not deal with these. I am not absolutely certain that this explanation is correct, but here is my reasoning, based on trying various combinations of svn and ssh clients on Windows:
  1. cygwin svn / cygwin ssh: worked fine (the error messages were visible, but ignored, and the svn operation worked)
  2. collabnet svn / TortoisePlink: "network connection closed unexpectedly"
  3. collabnet svn / cygwin ssh: worked fine!
I worked around the problem by changing my login shell to /bin/tcsh on the Solaris machine: that made the error messages go away, I guess because bash is installed incorrectly on that machine.

Once I changed my login shell to eliminate the error messages, the latest version of Tortoise (1.6.5) was able to connect to a remote svn+ssh repository.

Now, if I could somehow get back the hours I spent figuring this out... :-)

1 comment:

Unknown said...

Thanks for posting the info, helped me figure out why debian / bash wouldn't handle syncing my perl scripts.