Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to add a user in svn on an Ubuntu machine, how would I go about doing that?

share|improve this question

migrated from Sep 19 '09 at 12:16

This question came from our site for professional and enthusiast programmers.

What kind of svn server do you have? file, svn, http? – Wienczny Sep 18 '09 at 23:18
up vote 3 down vote accepted

In your SVN repo (note: not the checkout) there is a directory called "conf". In that directory are a few files that control users and their access to the repo:

  • svnserve.conf
  • passwd
  • authz

Read the notes at the top of those files and you should be able to add a new user and configure their read/write access to the repo.

share|improve this answer

In case you are using HTTP/WebDAV access:

  1. Locate the htpasswd file you use for listing users. This path can be found in the apache configuration for your server - grep for the word AuthUserFile.
  2. Enter htpasswd thepathtothatfile theusernametoadd
  3. When prompted enter the new password for the user, and repeat it to confirm.
  4. Now restart/graceful the apache instance controlling your repository (propably something like apache2ctl -k graceful

The user should now be active on the repository. If you also have per-directory access control set up, follow these steps as well:

  1. Locate your per-directory permissions file - grep your apache config for the term AuthzSVNAccessFile ; this will give you the path (if it is set).
  2. Either add a directory to the file ([/directory/from/root/of/repo]), or select an existing entry.
  3. Add that user underneath the appropriate entry, specifying rw for full access, or r for read-only.

Here is a sample per-directory access file:

admin = rw

sarah = rw
mike = r
share|improve this answer

I found a few examples that does what you want. It does however depend on how subversion was installed (web or no web).

share|improve this answer

Go to conf Directory in your repo

Open svnserver.conf and uncomment/add these lines if they are already not.
anon-access = read
auth-access = write
password-db = passwd

Open file named passwd in conf directory to add users, one way to add users easily is to add a line for the new user account in the format "user=password" (no quotes) to the file

Hope that helps .. :)

Mahesh Velaga.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.