Mercurial over ssh client and server on Windows
- by Ben Von Handorf
I'm trying to configure Mercurial for use with both a windows server (freeSSHd) and client (both command line and TortoiseHG). I'm using the most recent versions of everything... all downloaded in the past few days. Using public key auth, I have been able to get connected to the server and I'm able to use plink to execute "hg version" and get a response, but when I try to clone a repository from the ssh server the command appears to hang. Running with -v yields:
hg -v clone ssh://<username>@<server>//hg/repositoryA testRepositoryA
running "plink.exe -i "<path to private key file>" <username>@<server> "hg -R /hg/repositoryA serve --stdio""
with nothing more forthcoming. Running the hg serve command directly on the server yields an apparently responsive Mercurial server, but the clients do not seem to make any further requests.
Running "hg serve" in the repository directory and cloning over http works perfectly.
What should I be looking for to help debug this? Is there something the clients (hg and TortoiseHG) aren't sending to continue the request stream?
Additional Information:
If I change to an invalid repository on the target machine, the appropriate error is displayed, so it does appear that the remote hg is running and correctly evaluating the path.
Running with --debug and --traceback results in:
sending hello command
sending between command
It hangs here, until I CTRL-C
Traceback (most recent call last):
File "mercurial\dispatch.pyo", line 46, in _runcatch
File "mercurial\dispatch.pyo", line 452, in _dispatch
File "mercurial\dispatch.pyo", line 320, in runcommand
File "mercurial\dispatch.pyo", line 504, in _runcommand
File "mercurial\dispatch.pyo", line 457, in checkargs
File "mercurial\dispatch.pyo", line 451, in <lambda>
File "mercurial\util.pyo", line 402, in check
File "mercurial\commands.pyo", line 636, in clone
File "mercurial\hg.pyo", line 187, in clone
File "mercurial\hg.pyo", line 63, in repository
File "mercurial\sshrepo.pyo", line 51, in __init__
File "mercurial\sshrepo.pyo", line 73, in validate_repo
KeyboardInterrupt
interrupted!
Responding to Ryan: There does not appear to be any CPU usage or increasing memory usage on the server. It appears to be waiting for the client to send a request or something similar.
11/19/2009 : More information:
The problem is definitely in the freeSSHd/server side of the equation. Connecting to bitbucket over ssh with the same keyset works fine. Still working on this.