High Availability of hg web server through NFS share

Matt Mackall mpm at selenic.com
Wed Aug 10 20:22:56 UTC 2011


On Tue, 2011-08-09 at 21:04 +0200, Christophe Furmaniak wrote:
> Hi,
> 
> I would like to provide high availability of a mercurial "central"
> repository using several (at least 2) apache web servers + hgweb.cgi that
> would serve a shared NFS partition.
> 
> Will it work as expected or may I encounter some kind of locks because of
> the shared NFS partition?

Should be fine, provided you've got non-buggy NFS clients and servers.

In general, this should scale pretty well. You'll get best results by
load-balancing such that clients are grouped to servers by project, but
random load-balancing will also work. Lots of memory on clients for
caching will also be helpful.

I'm pretty sure Bitbucket is using NFS at some level, as it's pretty
much a given for cloud-based systems. The alternative (block-based
storage protocols) isn't really sharable. 

(Technically, you also need to have a highly-available NFS server to
have a real HA solution, and that ends up being a tricky problem. It
really calls for a fault-tolerant distributed filesystem like GFS or
Ceph.)

-- 
Mathematics is the supreme nostalgia of our time.





More information about the Mercurial mailing list