Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a subversion server that is running short on disk. I'd like to archive one of the larger repositories to free up some space, so I need to make a full backup of the repository files on a remote server. unfortunately the repo is quite large, which limits several easy options:

  • I can't use svn dump or svn hotcopy because there is not enough local storage available for a full copy of the repository.
  • I can use rsync, but the svn server is using the older berkeley db and it seems this can create a corrupt backup. the repo is not actively being used, but it is possible that someone my still alter it while the rsync is running. stopping the SVN service is not a good option in this case as the server is heavily used.
  • I've used a utility called rsvndump in the past, and my experience is that while it would be ideal for this situation, it tends to die prematurely and consistently on large repositories, resulting in an unusable archive.
  • svnsync seems reasonable, but would require additional configuration steps on the remote server, and it seems like the archive is somewhat fragile compared to an actual data dump. it also seems like overkill for what is essentially a one-off task.

I'm looking if there is a way to run svndump or hotcopy via rsync or an ssh pipe, to make a "local" archive on a remote host. it's imperative that the backup be valid as I will need it to restore once the disk space issue has been resolved.

share|improve this question

1 Answer 1

I can't use svn dump or svn hotcopy because there is not enough local storage available for a full copy of the repository.

The svnadmin dump command sends the output to stdout. It would be trivial to do something like ssh svn-server.example.org svnadmin dump > /tmp/svn_backup. The dump output would exist on the computer you ran SSH from, not on the server. You shouldn't need any additional space on the SVN server.

share|improve this answer
    
Excellent! My file system went read-only on me, and I wanted to get a dump, since just pulling off the files in the repo is risky, especially if I have to build a new server with a newer release of svn. –  gbarry Feb 12 at 3:12

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.