So we've been setting up a new subversion server recently and eventually got it live yesterday, and things seemed to go smoothly.
That is until some commits started failing randomly.
Subversion has the concept of commit hooks, and in particular, a pre-commit hook that is called (you guessed it) before a transaction is committed. It simply executes any application or shell script, and aborts the transaction if the return value is non-zero. It's a very simple, yet powerful way of enforcing various conditions on how commits work.
However, we found that about a third of the time, the pre-commit hook appeared to be failing. After various changes to the script to try and detect what was going on, we replaced it with a script that simply always returned 0 - i.e. it should always work.
It still failed about a third of the time.
Interesting... Especially since I extensively tested commits prior to go-live without any problems whatsoever.
After lots of banging our heads against the desks, I eventually found a reference in a use group noting a potential incompatibility between Apache running subversion, and php. So I disabled php, and restarted Apache.
It worked perfectly...
After further investigation I now suspect that the problem is actually WebSVN, as it appears that the commit problems do not occur until after the web client is used to browse that repository. But as soon as the web client is used, commit failures seem to start occuring every so often.
But that seems weird, as this would imply WebSVN, a web client specifically for Subversion, simply doesn't work. Maybe it is because we have a 64-bit machine, but I haven't been able to verify this.
Anyway, we now have dropped WebSVN and installed ViewVC instead, and it appears (fingers crossed) to all be working correctly.


Trackbacks
TrackBack URL for this entry:
http://www.cloudsofheaven.org/cgi-bin/mt-tb.cgi/197.