[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svnadmin hotcopy failing

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2004-05-13 17:43:22 CEST

On Thu, 2004-05-13 at 10:35, Scott Lawrence wrote:

> > 1. cp -R repos repos-backup
> > 2. cp repos/db/log* repos-backup/db/
> > 3. svnadmin recover repos-backup
> >
> > You could even write a shell script to do this.
>
> Just out of curiosity; what is the point of (2)? isn't that implied by
> the -R in (1)?

Because the database is "hot", table files and logfiles may be actively
changing while you're copying them. You might end up with half a change
in a table.

That's okay, because the logfiles journal every change. But means that
the only way to guarantee that your repos-copy is consistent is to copy
the logfiles *last*. 'svnadmin recover' then reads those journals to
rollback the database to a consistent state.

(If your database isn't being accessed at all, then you only need to
step 1 to make a backup.)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Thu May 13 17:48:29 2004

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.