0

Per the SVN documentation (http://svnbook.red-bean.com/en/1.7/svn.ref.svnadmin.c.hotcopy.html), you can only run svnadmin hotcopy with local repositories.

Is there any way to run this command using a remote SVN repository, using the URL?

I essentially want to make a complete copy of my huge SVN repository (over 6000 versions), including all history, tags, versions etc. and store it on my local machine, completely independent of the remote repository.

Idris.AH
  • 410
  • 1
  • 10
  • 22

2 Answers2

2

Subversion 1.7 introduced svnrdump, a means by which you can create a dumpfile of the repository, remotely. You can then load that dumpfile into a local repository with svnadmin load.

alroc
  • 27,574
  • 6
  • 51
  • 97
  • I have used `svnrdump` previously, but, this repository is too large and I don't have direct access to it. I am connecting through a proxy. It usually gets to revision 50 and then times out. It took 2 hours to get to revision 50. Is there any alternative? – Idris.AH Nov 29 '17 at 16:57
  • @JonnySprouse without direct filesystem access, this is the only way. What problem are you attempting to solve by creating a local clone of the whole repository history? – alroc Nov 29 '17 at 19:35
  • I am trying to migrate the SVN repository to Git using svn2git (KDE version), and I need a dump/local copy for: 1. To use svneverever to help me write rules for svn2git 2. To run svn2git with a local copy instead of the remote repository, since it will reduce a lot of overhead and run time, which is crucial with it being a huge repository. Can I combine multiple dump files into one single repository and it be exactly the same as the online repository (at the time of dumping), with all the tags, versions etc. – Idris.AH Nov 30 '17 at 09:55
  • Yes, you can perform incremental dumps and then load them into a repository sequentially. But if you're doing a conversion to git (I presume to leave SVN entirely), you should be working with your server admin and getting direct access to the repository to make the hotcopy, not attempting janky workarounds like this. – alroc Nov 30 '17 at 12:25
  • Could I ask, why would a hotcopy be better than a dump? Is hotcopy best for getting all the versions, tags and all history? etc. I realise that if I had a hotcopy, I wouldn't then need to load the dump into my own repository, I'd already have it all there, correct? – Idris.AH Dec 01 '17 at 09:18
  • Hotcopy will be faster and smaller. The end result (after loading a dump file into a new repository) is the same though. – alroc Dec 01 '17 at 11:01
-1

I tried lots of different methods including svnadmin hotcopy but the best in the end without a doubt was simply svn dump such as this taken from the svn book. svnadmin dump /var/svn/repos > full.dump link here once you have done that pack it up and send it to where you want the repository. I tried pretty much everything else and this was the simplest and the best for me. I seem to remember that it automatically set the UUID which is the unique identification number of your Subversion project. If you want to use it as the original then it needs to be the same UUID, if it is different use the setuuid command such as svnadmin setuuid /var/svn/repos-new 2109a8dd-854f-0410-ad31-d604008985ab http://svnbook.red-bean.com/en/1.6/svn.ref.svnadmin.c.setuuid.html