Subversion backup and restore

From ArchWiki
Revision as of 05:27, 25 April 2013 by Fengchao (Talk | contribs) (Move to Subversion Setup.)

Jump to: navigation, search

Tango-edit-clear.pngThis article or section needs language, wiki syntax or style improvements.Tango-edit-clear.png

Reason: please use the first argument of the template to provide a brief explanation. (Discuss in Talk:Subversion backup and restore#)

This article deals with how to backup your Subversion data and move it to a new machine. For a detailed article on setting up Subversion, see Subversion Setup.

Instruction

svnadmin dump repo and scp to other machine Do this for each repository you have.

svnadmin dump /path/to/reponame > /tmp/reponame.dump ; scp -rp /tmp/reponame.dump user@server.domain.com:/tmp/

Create the corresponding repositories. Do this for each repository you have.

svnadmin create /path/to/reponame

Load svn dump into new repo on new machine. Do this for each repository you have.

svnadmin load /path/to/reponame < /tmp/repo1.dump

Setting Permissions.. CRUCIAL This is the most common mistake when moving an svn repo. Do this for each repository you have.

chown -R svn:svnusers /path/to/reponame ; chmod -R g+w /path/to/reponame/db/

Ok these repos should be all set and ready to rock..