Thursday, September 20, 2012

SVN upgrade errors and solutions


I ran into some Subversion issues while upgrading an old Subversion instance from 1.5.5 to 1.7. The process also involved moving the repositories from a 32bit 1CPU 2GB virtual server to a 64bit 2CPU 4GB virtual server.  I’m also running Subversion Edge, as the svn user and apache as the apache user.
  
Subversion (SVN): Can’t open file ‘db/txn-current-lock’: Permission denied
Discussion: Ownership on the repository db directory is incorrect
# ls -ld /<repo-path>/<repo>/db
drwxrwsr-x 6 svn svn 4096 Sep 20 12:45 db

Solution:  Change ownership
                # chown –R svn:apache db
 ==========================================================

Subversion (SVN): Can’t write activity db

Discussion: Ownership on the repository dav directory is incorrect
# ls -ld /<repo-path>/<repo>/dav
drwxrwxr-x 3 svn apache 4096 Sep 19 17:04 dav

Solution: Change ownership of the dav directory
          # cd /<repo-path>/<repo>/
    # chown –R apache:apache dav

 ==========================================================  

Subversion (SVN): “attempt to write a readonly database”

Discussion: The file “rep-cache.db” has the incorrect permissions
#ls -l rep-cache.db
-rw-r--r-- 1 svn apache 81920 Sep 20 13:09 rep-cache.db

Solution: Change ownership on rep-cache.db
    # cd /<repo-path>/<repo>/db
    # chmod 664 rep-cache.db

No comments:

Post a Comment