Downgrade svn repository db format from 1.6 to 1.5

旧巷老猫 提交于 2021-02-07 06:35:06

问题


I do have an unusual situation, because I have to migrate an svn repostitory from svn-server 1.6 to svn-server 1.5. The issue is that the are no tools for downgrade available. Do anyone know some scripts or have the expirience with downgrading of svn repositories?

Cheers,

Kevin


回答1:


You could use svnsync to move the content from one repository to another.

Normally svnsync is intended for keeping a read-only mirror up to date, but I believe it will work fine for a one-time migration also. It also has the advantage of working purely as an SVN client, so you don't need administrative access on the server.




回答2:


Apart from Wim's suggestion svnsync the other option is a full dump / reload; use the Subversion 1.6 svnadmin to dump the repostitory out e.g.

svnadmin dump --incremental --deltas > dump_file

and then use 1.5 tools to load this back in to a clean repository

svnadmin create repository_15
svnadmin load repository_15 < dump_file

You will then have to copy over hooks from the old repository into the new repository and run svnadmin pack if you use that, etc.




回答3:


Since subversion 1.8, it is possible to create a compatible repository without switching tooling.

Extract

Extract the contents of the existing subversion repository using svnadmin dump or svnrdump for remote repositories:

svnadmin dump --incremental --deltas /path/to/local/repository > /tmp/repository.dump

Recreate as v1.5 Compatible

Using svnadmin create a new 1.5 compatible repository and load in the previously dumped contents:

svnadmin create --compatible-version 1.5 /path/to/local/repository_15
svnadmin load /path/to/local/repository_15 < /tmp/repository.dump

Hooks and other repository settings will not be carried over and will need to be set up manually.

Subversion 1.7

Subversion 1.7 supports the ability to create compatible repositories using the deprecated --pre-1.6-compatible flag.



来源:https://stackoverflow.com/questions/4780751/downgrade-svn-repository-db-format-from-1-6-to-1-5

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!