RE: How to safely back up an svn repository on ubuntu?
From: Juan Gabriel Covas <jgcovas_at_softline.es>
Date: Wed, 13 Jan 2021 12:12:22 +0000
If it helps, I use the following one-liner to "svnadmin hotcopy --incremental", so only new revisions are copied each time (the svn-hot-copies target path is a NFS mount, for example, in other box)
# find /path/to/your/repos -maxdepth 1 -mindepth 1 -type d -printf "%f\0" | sort -z | xargs -0 -I % sh -c 'echo %; svnadmin hotcopy --incremental /path/to/your/repos/% /path/to/svn-hot-copies/repos/%;'
Regards,
Juan G. Covas
De: Mark Phippard <markphip_at_gmail.com>
On Wed, Jan 13, 2021 at 6:16 AM Bo Berglund <mailto:bo.berglund_at_gmail.com> wrote:
The repositories reside in /var/lib/svn and comprise about 6 Gb worth of files
The backup SVN server runs on an Ubuntu 18.4 LTS server in my home network and
I got a problem with it a few days ago when we had a power outage and the Ubuntu
I have now set up an NFS connection between the Ubuntu server and the Synology
So what I had in mind is to somehow keep a copy of the repository files on the
I could use tar but that would be complex since there are certainly not many
I am a user of Ubuntu Linux for some of my work and have had to learn the basics
I don't know if some actions should be done towards svn on the ubuntu server in
I would use rsync. Especially since this sounds like it is mainly a last resort backup. There are some relatively minor problems that can happen if rsync happens to run in the middle of a transaction. The rsync still works but it could make a backup of the repository in an incomplete state. Those problems are fixable and the next rsync would still work and would fix the problem too.
The safer way is to use svnadmin hotcopy but you would have to script it since you need to run it for each repository. The advantage of rsync is that you can just process the entire root folder where your repositories are stored.
-- Thanks Mark Phippard http://markphip.blogspot.com/Received on 2021-01-13 13:52:19 CET |
This is an archived mail posted to the Subversion Users mailing list.
This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.