2007-12-16

Migrate a Subversion Sub Repository

Migrate SVN


Description:

Instructions to migrate a sub repository to it's own repository.

Get a copy of the repo:
    cp -r me@myserver:/usr/local/data/svn/myrepo .
Dump it:

svnadmin dump --quiet myrepo > myrepo.DUMP
Filter the hunk you want:

cat myrepo.DUMP | svndumpfilter include MySubProject > MySubProject.DUMP|more

copy it to the new server (omit this if doing it on the new server):


scp MySubProject.DUMP robrien@myotherserver:~/

Logon:


ssh robrien@myotherserver

Create a new repo:


sudo ./bin/svnadmin create /usr/local/repos/MySubProject
sudo chown -R www:www /usr/local/repos/

Load the repo:

    sudo svnadmin load --quiet /usr/local/repos/MySubProject < /usr/home/robrien/MySubProject.DUMP

Done.

No comments: