With my recent move over to Linux. over this last week I have been resetting up my file server and getting everything setup that way it was back when it ran that other operating system. On of the functionalities my file server has, is running a subversion server. There are many ways to setup subversion, tapped into apache, using xinetd, running as a daemon, ssh, ssl… the list goes on. At home I am behind a firewall and this server has no access to the outside word, so for me it was definitely a KISS (keep it simple stupid) moment. I chose to setup subversion with xinetd. Now Ubuntu made this dead simple, but I like to learn how to do things manually as that’s the spirit of being a geek. So lets take a look at hoe to get this thing up and running:
1) Install Subversion and xinetd
There are many ways to accomplish this: Yum, apt-get, up2date, or your favorite package manager. For this tutorial lets use apt-get.
[ftf]
apt-get install subversion
apt-get install xinetd
[/ftf]
2) Create a Subversion Repository
Your repositories can be located anywhere, for me there were on a NAS device. we use the fantastic tool ’svnadmin’.
[ftf]
svnadmin create /path/to/your/svn/myfirstrepository
[/ftf]
3) Configure xinetd
In this step we will configure the superserver to make it run an svn service. The configuration file for xinetd is located at ‘/etc/xinetd.conf’ under most circumstances. The configuration file should look something like the one below. Make note of the path to where your repositories are located, not the path to the actual repositorie: ‘/path/to/your/svn’. Also make note of the ‘user’ parameter. Whatever you set this user to, needs to have read and write access to your svn path.
[ftf]
# Simple configuration file for xinetd
#
# Some defaults, and include /etc/xinetd.d/
defaults
{
}
service sshd
{
port = 22
server = /usr/sbin/sshd
}
service svn
{
port = 3690
socket_type = stream
protocol = tcp
wait = no
user = www-data
server = /usr/bin/svnserve
server_args = -i -r /path/to/your/svn
}
includedir /etc/xinetd.d
[/ftf]
4) Setup User Access to Your Repositories
Subversion has many ways you can setup access to your repositories, for the sake of this tutorial lets just setup a simple user name and password. Modify the file ‘/path/to/your/svn/myfirstrepository/conf/svnserve.conf’ and setup the simplest way of adding users, with the ‘passdb’ file. Your file should look something like this;
[ftf]
anon-access = none
auth-access = write
password-db = passwd
[/ftf]
What you are doing here is letting subversion no that users with no authentication access ‘anon-access’ should have no access to this repository, and users with authentication ‘auth-access’ access should have write access. The last line is letting subversion that we are using the ‘passwd’ file located in the same directory for the user list. That file, ‘/path/to/your/svn/myfirstrepository/conf/passwd’, you can now add users in the format of:
[ftf]
username = password
[/ftf]
5) Conclusion
Now, if all went well, you should be able to check out from your new repository:
[ftf]
svn co svn://localhost/myfirstrepository
[/ftf]
If you want more information on how to setup a subversion server including running it with apache, ssh, ssl, or other methods; I highly recommend the “Version Control with Subversion” book.

[...] Link to Article linux How to Setup a Subversion Server on Linux » Posted at Code and Coffee on [...]
I really think it’s a bad idea to be promoting and using a non-distributed version control system. In case you haven’t noticed, all the big projects are moving away from the non-dvcs model in favor of cheap branches and smart, quick merging.
I suggest you look at Git and Mercurial. Git was written by Linus Torvalds for the Linux kernel and so was Mercurial. Also, check out the Google tech talks on both. Linus’ tech talk on Git will make you feel stupid for not writing it yourself ;-P Even though he’s harsh, he’s got a point.
Hey Luke, get a life and stop being religious about version control systems that nobody is using.
[...] while back I wrote an How To on how to setup a Subversion server on Linux. So anything you can do on Linux you should be able to do on Windows, right? Well I am not getting [...]
Many thanks,
very simple and clear to understand. In addition to the svn book this was exactly the information I was missing to get up and running.
With this information it’s cake to get up and running!