Slow hgweb.cgi

Matt Mackall mpm at selenic.com
Tue Apr 12 09:56:42 CDT 2011


On Tue, 2011-04-12 at 16:42 +0200, Dominik Psenner wrote:
> > -----Original Message-----
> > From: Matt Mackall [mailto:mpm at selenic.com]
> > Sent: Tuesday, April 12, 2011 4:39 PM
> > To: Dominik Psenner
> > Cc: 'Patrick Mézard'; 'Mercurial Developers'
> > Subject: RE: Slow hgweb.cgi
> > 
> > On Tue, 2011-04-12 at 15:07 +0200, Dominik Psenner wrote:
> > > Pushing/pulling to/from the repository directly to the samba share works
> > > flawless and goes through in a jiffy. Doing the same pull without
> > changes
> > > takes a total of about 16 seconds.
> > >
> > > hg --repository XXX-hg pull --verbose --update --config
> > > ui.merge=internal:fail --debug http://hgserver/hg/XXX/
> > > using http://hgserver/hg/XXX/
> > > sending between command << about 4secs in here
> > > Hole von http://hgserver/hg/XXX/
> > > sending heads command << about 4secs in here
> > > Suche nach Änderungen
> > > Keine Änderungen gefunden
> > > checking for updated bookmarks
> > > sending capabilities command << about 4secs in here
> > > capabilities: changegroupsubset stream=1 lookup pushkey
> > > unbundle=HG10GZ,HG10BZ,HG10UN branchmap
> > > sending listkeys command << about 4secs in here
> > >
> > > So the server takes nearly constantly 4seconds to respond on each
> > command
> > > sent. Ideas?
> > 
> > Is this time similar to the time it takes to browse pages in the web
> > interface?

[de-top-posted]

> Yep, it is. With top I can observe that a python process is on heavy load
> during that time and I assume that it is the one invoked by hgweb.cgi.

Yeah, that's very unusual. Even with the slow CGI interface (which is
basically reloading Python, Mercurial, and the index for every request),
your repo is small enough that this should take well under a second.

I suspect your network filesystem is somehow to blame.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list