Slow hgweb.cgi

Adrian Buehlmann adrian at cadifra.com
Wed Apr 13 04:44:34 CDT 2011


On 2011-04-13 08:44, Dominik Psenner wrote:
> *argh* I could bang my head on the table. I just did:
> 
> 1 cloned the complete hgweb.cgi to another url (hgserver/hg2)
> 2 set up a repository folder that is not a samba share (mkdir)
> 3 copied the biggest repository to that folder
> 4 ran a hg pull from my pc
> 
> Guess what? It went through within a jiffy. So the problem is indeed
> smb/cifs. Yet I do not fully understand what's going on because it doesn't
> seem to be a timeout issue where hgweb.cgi is just waiting for the smb
> share.
> 
> I used to set it up with autofs:
> 
> -- quote auto.cifs --
> $ cat /etc/auto.cifs
> HGRoot -fstype=cifs,rw,credentials=/etc/samba/cred-file,uid=www-data,gid=hg
> ://"dc1/Disk_X/HGRoot/"&
> -- eof quote--
> 
> The script goes into a heavy operation that consumes one core completely for
> a rather long time where it has no obvious reason to do that. *hm* It feels
> like there's something in hg or hgweb that causes problems, but I can't
> really confirm it. It just feels like hgweb is somehow doing:
> 
> If samba
>    Heavy loop
> Continue

Do you see any unusual slowness if you enter

  $ dir \\servername\sharename

or

  $ dir \\servername

Note that the second should fail, but I'm interested in how fast it fails.

I'm still not so sure about the WebDAV stuff not being an issue
(kb/832161)...

Might be time to fire up wireshark and have a look at the messages
exchanged.

BTW, may I ask you to add your replies underneath the message you are
replying to? (No top-posting).

FWIW, I'm not really a fan of putting repositories on windows shares.
I'm just puzzled that people apparently still keep trying doing it.




More information about the Mercurial-devel mailing list