after upgrading a SVN server from 1.6 to 1.7.2 (r1207936), I am getting
this error message when committing:
svn: E175002: Commit failed (details follow):
svn: E175002: Server sent unexpected return value (500 Internal Server
Error) in response to POST request for '/repos/svntest/!svn/me'
The corresponding error on the server is:
(20014)Internal error: Can't open file '/srv/svn/repos/!svn/format': No
such file or directory
My apache configuration on the server includes:
<Location /repos/>
DAV svn
SVNParentPath /srv/svn/repos/
SVNListParentPath on
...
</Location>
I am unsure what could be wrong and what those error messages mean.
Has anyone a few hints?
Thanks a lot
Pierre
> Hi
>
> after upgrading a SVN server from 1.6 to 1.7.2 (r1207936), I am
> getting this error message when committing:
>
> svn: E175002: Commit failed (details follow):
> svn: E175002: Server sent unexpected return value (500 Internal Server
> Error) in response to POST request for '/repos/svntest/!svn/me'
>
> The corresponding error on the server is:
> (20014)Internal error: Can't open file '/srv/svn/repos/!svn/format':
> No such file or directory
>
> My apache configuration on the server includes:
>
> <Location /repos/>
> DAV svn
> SVNParentPath /srv/svn/repos/
> SVNListParentPath on
> ...
> </Location>
>
I have discovered that if I stop using path-based authorization by
setting SVNPathAuthz Off instead of On, the problem disappear. I have
also tried the value "short_circuit" for SVNPathAuthz, but it does not
change the error compared to "SVNPathAuthz On".
Anyone a clue what this means?
s/SVNParentPath/SVNPath/ probably. If that fails show us
% ls /srv/svn/repos/
> Thanks a lot
> Pierre
>
Hmm. Not clear what to do here but I suspect a little more information
about your setup would help. (First rule of reporting bugs in
fundamental features: it literally works for +- everyone else.)
Also, perhaps lose the trailing slash in the <Location> directive:
<Location /repos>
> Hi
>
> after upgrading a SVN server from 1.6 to 1.7.2 (r1207936), I am
> getting this error message when committing:
>
> svn: E175002: Commit failed (details follow):
> svn: E175002: Server sent unexpected return value (500 Internal Server
> Error) in response to POST request for '/repos/svntest/!svn/me'
>
> The corresponding error on the server is:
> (20014)Internal error: Can't open file '/srv/svn/repos/!svn/format':
> No such file or directory
>
> My apache configuration on the server includes:
>
> <Location /repos/>
> DAV svn
> SVNParentPath /srv/svn/repos/
> SVNListParentPath on
> ...
> </Location>
>
(Thanks to Daniel Shahaf for his advice in an earlier email)
I have now reduced my configuration to two variations, the following
works fine:
<Location /repos/>
DAV svn
SVNParentPath /srv/svn/repos/
SVNListParentPath on
AuthzSVNAccessFile /etc/apache2/svnaccess.conf
AuthzSVNAnonymous Off
AuthzSVNAuthoritative On
SVNPathAuthz On
AuthType Basic
AuthName "Login required"
AuthBasicProvider ldap
AuthLDAPURL
ldap://......
Require valid-user
</Location>
With some repositories in /srv/svn/repos/:
$ ls -l /srv/svn/repos/
drwxr-xr-x 6 wwwrun www 4096 2011-12-22 21:14 svntest
drwxr-xr-x 6 wwwrun www 4096 2011-12-22 22:05 svntest2
and the content of /etc/apache2/svnaccess.conf:
$ cat /etc/apache2/svnaccess.conf
[/]
* = rw
Now the following variation does not work: I wanted to disable
path-based authentication in general, and enable it on a per-repository
basis, so I have changed the above config to this (only differences are
the SVNPathAuthz parameters):
<Location /repos/>
DAV svn
SVNParentPath /srv/svn/repos/
SVNListParentPath on
AuthzSVNAccessFile /etc/apache2/svnaccess.conf
AuthzSVNAnonymous Off
AuthzSVNAuthoritative On
SVNPathAuthz Off
AuthType Basic
AuthName "Login required"
AuthBasicProvider ldap
AuthLDAPURL
ldap://......
Require valid-user
</Location>
<Location /repos/svntest/>
SVNPathAuthz on
</Location>
Now this does not work and I get the error messages I have previously
reported. If I comment out the "Location /repos/svntest/" section, it
works again.
I am now wondering if that should be considered a bug at all, or is
this expected behaviour? My rational in setting SVNPathAuthz Off
globally was to save server resources as explained in the svn book
section:
http://svnbook.red-bean.com/en/1.7/svn-book.html#svn.serverconfig.httpd.authz.pathauthzoff
and I thought enabling it again per repository only if needed would at
the end be optimal. It used to work fine with 1.6 (meaning: without
errors), and this problem started with 1.7 so that hints to some kind
of regression (?).
Cheers
Pierre
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Pierre Berthier
CIO / Leiter IT
Institute of Neuroinformatics, 55.G.70
University of Zurich and ETH Zurich
Winterthurerstrasse 190, CH-8057 Zurich, Switzerland
Tel: +41 (0)44 63 530 17
Fax: +41 (0)44 63 530 53
> <Location /repos/>
> DAV svn
> SVNParentPath /srv/svn/repos/
> SVNListParentPath on
> AuthzSVNAccessFile /etc/apache2/svnaccess.conf
> AuthzSVNAnonymous Off
> AuthzSVNAuthoritative On
> SVNPathAuthz Off
>
> AuthType Basic
> AuthName "Login required"
> AuthBasicProvider ldap
> AuthLDAPURL
> ldap://......
> Require valid-user
> </Location>
>
> <Location /repos/svntest/>
> SVNPathAuthz on
> </Location>
Wow! A nested Location without "DAV svn" but with a Subversion
directive. I can see that we might be able to make that work, but I'm
not sure that we ever did. Does that work in 1.6?
You may be able to work around the problem by making /repos/svntest into
a self-contained "DAV svn" Location by adding SVNPath,
AuthzSVNAccessFile, etc.
If this was supported by 1.6 and the problem only occurs with POST
requests then you may be able to work around it by disabling the v2
protocol.
--
Philip
(Thanks for the additional details, it's _much_ easier to respond
usefully given them.)
> I am now wondering if that should be considered a bug at all, or is
> this expected behaviour? My rational in setting SVNPathAuthz Off
> globally was to save server resources as explained in the svn book
> section:
> http://svnbook.red-bean.com/en/1.7/svn-book.html#svn.serverconfig.httpd.authz.pathauthzoff
>
> and I thought enabling it again per repository only if needed would at
> the end be optimal. [...]
If you use 'SVNPathAuthz short_circuit" and supply an empty (0-byte, or
"[/]\n *=rw") authz file for repositories that don't need authz, I think
the effect on server resources will be minimal.
(The code will still try to authz every path, but the overhead of
reading/parsing/applying the authz file will be small.)
Though, in general, agreed with Philip here --- it'd be nice if
per-repository httpd.conf settings in SVNParentPath configurations
Just Worked.