There appears to be a bug in SVN 1.5 which causes merges to a working copy to fail when using mod_dav_svn. This bug only happens when using svn server > 1.4 and svn client > 1.4 with mod_dav_svn. Here are the steps to reproduce:
OS: Debian Lenny (stable)
SVN server/client (1.5.1 from debian repository)
svnadmin create /svn chown -R www-data /svn # NOTE: apache user maybe be different depending on linux distro
<VirtualHost *:80>
ServerName svn.example.org
CustomLog /var/log/apache2/svn-access.log combined
ErrorLog /var/log/apache2/svn-error.log
<Location /svn>
DAV svn
SVNPath /svn
AuthType Basic
AuthName "Subversion Repository"
AuthUserFile /etc/svn/svn-user-file
AuthzSVNAccessFile /etc/svn/svn-auth-file
Satisfy Any
Require valid-user
</Location>
</VirtualHost>
mkdir -p /etc/svn htpasswd -cb /etc/svn/svn-user-file petee mypassword cat <<EOF> /etc/svn/svn-auth-file [/] petee = rw [/public] * = r petee = rw EOF
svn co http://svn.example.org/svn cd svn mkdir -p public/trunk svn add public svn -m "initial commit" commit
svn cp -m "branching trunk" http://svn.example.org/svn/public/trunk http://svn.example.org/svn/public/branch svn up
cd public/trunk touch test.txt svn add test.txt svn -m "" commit cd .. svn merge -c 3 http://svn.example.org/svn/public/trunk branch # NOTE: nothing happened :(
As you can see, the merge failed and provided no output at all.
Allow read access to root of repository. NOTE: this workaround is unacceptable as it gives the anonymous user read access to the entire repository.
If I change the /etc/svn/svn-auth-file to contain the following, the merge succeeds:
[/] * = r petee = rw [/public] * = r petee = r
root@dekidev:~/svn/public# svn merge -c 3 --dry-run http://svn.example.org/svn/public/trunk branch --- Merging r3 into 'branch': A branch/test.txt
Use an older SVN client (svn 1.4). NOTE: This is unacceptable since most developers use Tortoise SVN > 1.4
[root@localhost ~]# svn --version svn, version 1.4.2 (r22196) compiled Jan 21 2009, 20:11:00 Copyright (C) 2000-2006 CollabNet. Subversion is open source software, see http://subversion.tigris.org/ This product includes software developed by CollabNet (http://www.Collab.Net/). The following repository access (RA) modules are available: * ra_dav : Module for accessing a repository via WebDAV (DeltaV) protocol. - handles 'http' scheme - handles 'https' scheme * ra_svn : Module for accessing a repository using the svn network protocol. - handles 'svn' scheme * ra_local : Module for accessing a repository on local disk. - handles 'file' scheme
svn co http://svn.example.org/svn cd svn/public svn merge -c 3 --dry-run http://svn.example.org/svn/public/trunk branch A branch/test.txt
Use a blacklist instead of a whitelist. NOTE: there is some information leakage here since you can browse the root of the repository.
In the svn-auth-file, grant read access to the root of the repository and blacklist all other directories
[/] * = r petee = rw [/public] * = r petee = rw [/private] * = petee = rw
root@dekidev:~/svn/public# svn merge -c 3 --dry-run http://svn.example.org/svn/public/trunk branch --- Merging r3 into 'branch': A branch/test.txt
Use a different transport (svn+ssh or file://). NOTE: neither of these is a good solution :(
svn co file://localhost/svn svn2 cd svn2/public/ svn merge --dry-run file://localhost/svn/public/trunk branch --- Merging r2 through r4 into 'branch': A branch/test.txt
svn-auth-file
[/] petee = rw [/public] * = r petee = rw
Apache log:
127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "OPTIONS /svn/public/trunk HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:22:51 -0500] "REPORT /svn/!svn/bc/4/public/trunk HTTP/1.1" 200 136 "-" "SVN/1.5.1 (r32289) neon/0.28.2"
svn-auth-file
[/] * = r petee = rw [/public] * = r petee = rw
Apache log:
127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "OPTIONS /svn/public/trunk HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "OPTIONS /svn/public/trunk HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "OPTIONS /svn/public/trunk HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/bc/0/public/trunk HTTP/1.1" 404 380 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/bc/4/public/trunk HTTP/1.1" 200 208 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "OPTIONS /svn/public/branch HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/branch HTTP/1.1" 207 692 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 388 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bln/4 HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn HTTP/1.1" 207 637 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/bc/0 HTTP/1.1" 200 112 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn HTTP/1.1" 207 637 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "OPTIONS /svn/public/branch HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/branch HTTP/1.1" 207 692 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/bc/4/public/branch HTTP/1.1" 200 281 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/vcc/default HTTP/1.1" 200 828 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/public/trunk HTTP/1.1" 207 690 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/vcc/default HTTP/1.1" 207 439 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bc/1/public/trunk HTTP/1.1" 207 424 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/bc/1/public/trunk HTTP/1.1" 207 1289 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "GET /svn/!svn/ver/3/public/trunk/test.txt HTTP/1.1" 200 - "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "PROPFIND /svn/!svn/ver/3/public/trunk/test.txt HTTP/1.1" 207 1189 "-" "SVN/1.5.1 (r32289) neon/0.28.2" 127.0.0.1 - - [13/Aug/2009:23:24:49 -0500] "REPORT /svn/!svn/bc/4 HTTP/1.1" 200 112 "-" "SVN/1.5.1 (r32289) neon/0.28.2
| Images 0 | ||
|---|---|---|
| No images to display in the gallery. |
Copyright © 2011 MindTouch, Inc. Powered by