Question

After my previous problem, TortoiseSVN Can't Connect was resolved, I ran into a new problem. On the linux server hosting my svn repository, in the repository's directory, there is a conf/svnserve.conf file. In this file, I have the option:

anon-access = none | read | write

Initially, this line was commented out and the default value must have been read. Of course, I want to set anon-access = none, and I want auth-access = write (which is the default).

But when I set anon-access = none, when I try to browse with TortoiseSVN Repository Browser using url svn://host:port/repositoryname, I get the error:

Unable to connect to a repository at URL 'svn://host:port/repositoryname' No access allowed to this repository

I'd like to successfully authenticate without ssh if possible, because I gather ssh has more moving parts and might be a little slower.

The server is CloudLinux Server release 5.8

The svn server information follows. I have only tried svn protocol so far.

svn, version 1.6.17 (r1128011) compiled Jul 26 2012, 03:59:19

Copyright (C) 2000-2009 CollabNet. Subversion is open source software, see http://subversion.apache.org/ This product includes software developed by CollabNet (http://www.Collab.Net/).

The following repository access (RA) modules are available:

  • ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
    • handles 'http' scheme
  • ra_svn : Module for accessing a repository using the svn network protocol.
    • with Cyrus SASL authentication
    • handles 'svn' scheme
  • ra_local : Module for accessing a repository on local disk.
    • handles 'file' scheme
  • ra_serf : Module for accessing a repository via WebDAV protocol using serf.
    • handles 'http' scheme
    • handles 'https' scheme

I hope this is a good question because this is kind of the "out of the box" behavior connecting to svn with windows, which might be pretty common when someone adds svn to a shared hosting account.

Thank you!

Was it helpful?

Solution

Set these lines in your svnserve.conf file:

 19 anon-access = none
 20 auth-access = write
    [...]
 27 password-db = passwd
    [...]
 39 realm = Name-of-your-repository
 46 force-username-case = lower

The line numbers are approximate.

The realm should equal the name of your repository. It can be anything. The password-db is who is authorized to use the repository. By default, the line is NOPed out.

Next, you'll edit the passwd file that's in the same directory. The format is very simple:

 <userName> = <password>

There are two NOPed entries that show you how it's done.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top