Mercurial & Windows Server 2003

这一生的挚爱 提交于 2019-12-08 07:06:32

问题


I just set up Mercurial on our main webserver, hosting repositories via hgwebdir.cgi. The problem I'm having now is when I run hg push from my local machine to the server's repository, it takes an absolutely ridiculous amount of time to push a very small directory, with only a single changeset. Is it possible that I've set something up wrong? I keep getting HTTP Error 502: Bad Gateway.

Thanks!


回答1:


Looks a bit like issue 2716 which suggests:

Here's a workaround for the problem you are having, basically instead of doing one huge push, you break it down into many smaller pushes:

  • 1/ find out the number of revisions of your repository,
  • 2/ c&p the following script, (in bash, use your favourite scripting language if you don't like bash):
    #!/bin/bash

    for rev in {1..NUM_OF_REVS}
    do
      hg push -r $rev REPO_URL
    done
  • 3/ grab yourself some snack.
  • 4/ If some of the pushes fail, don't worry, the following push will catch things up.

That being said, issues on Windows IIS has been reported as well.

This "blog post comment" also details:

  • I got the same error "Bad Gateway" and solved it. Think it's about: 1.Install Mercurial 1.2.1 on the server. The version that comes with TortoiseHg is not sufficient, it will not drive the CGI application.

  • I get a "Bad Gateway" exception when trying to run hgwebdir.cgi from a web application which exists on a different drive to my main system drive.

  • If you're using Mercurial 1.5 make sure you are using Python version 2.6.4 to run the cgi scripts in IIS.



来源:https://stackoverflow.com/questions/2700506/mercurial-windows-server-2003

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!