Configure password based subversion access via http for multiple users

Given the tight timeline to configure subversion with httpd access having multiple users, I found that it’s not a big deal. Although, as there’s excellent reference available online for subversion, this quick howto will be helpful to point out just the essential statements.

What I want:
A subversion server having multiple repository in /svn directory and accessible through http url like http://svn.example.com. You can not browse svn repositories without supplying a valid username/password. All users have read only access to all repositories while only one user ‘svnadmin’ have read/write (commit,update etc.) access to svn.

Fix subversion/svn child exit signal segmentation fault error in Apache

When running subversion with apache, how good config you’d done, you may still found that your svn repos are not accessible through http:// or https:// and most probably you’ll find this error in your apache error logs:

child pid 6485 exit signal Segmentation fault (11)

In my CentOS 5.2 box with httpd 2.2.3 and subversion 1.6.1, this error caused enough headache for me and claimed long time before I was able to find out the root cause. The problem is caused by collision of apr and apu utilities which are installed by both subversion and Apache. These packages are required to access svn via apache. The subversion-deps package contains apr and apr-util version 0.9.x, but apache 2.2.x uses apr and apr-util 1.2.x, and subversion and apache must be using the same version of apr and apr-util, else things can result in above error.

svn: Not authorized to open root of edit operation

I got this error from subversion running as daemon while trying to checkout the repository:

$ svn co svn://192.168.0.1/nomanager --username svnadmin
Authentication realm: <svn://192.168.0.1:3690> Nomanager Repository
Password for 'svnadmin':
svn: Not authorized to open root of edit operation

To solve this issue, you need to update the svnserve.conf file of that repository:

$ vi /svn/nomanager/conf/svnserve.conf

Change the line non-access = read to anon-access = none and try again.

You may also like to read:
* 5 steps to secure your Linux Server
* Ensuring secure access to production Linux Servers
* Bash script to backup essential log files in Linux
* Quickly change your ssh port from defualt 22 to something higher
* SSH port forwarding from remote to local machine
* Save root or user history to check later
* Install and configure denyhost to prevent brute force attacks