Projekt

Allgemein

Profil

Aktionen

SVN16 » Historie » Revision 1

Revision 1/2 | Weiter »
Jeremias Keihsler, 12.01.2017 14:28


Backup/Restore SVN repositories

Backup

The first thing you need when moving from one server to another is a dump of your subversion repository. Hopefully you are already creating dump's with a backup script, but if not here's how you can create a subversion dump file:

svnadmin dump /path/to/repository > repo_name.svn_dump

The dump file contains all the revisions you have ever made to your svn repository, so it will probably be quite large (it even includes files you may have deleted in a previous revision).

Restore

Now, simply transfer the dump file on to your new subversion server, and create an empty repository:

svnadmin create /path/to/repository

Next import your dump file:

svnadmin load /path/to/repository < repo_name.svn_dump

You may want to force subversion to use the same UUID for the new repository as the old repository. To do this add --force-uuid to your svnadmin load command. In my case I wanted to do this. If you have already loaded your repository, there is a way to set the UUID at a later date, check the docs.

That's it, you now have a replica of your old repository on your new server.

Von Jeremias Keihsler vor fast 8 Jahren aktualisiert · 1 Revisionen