You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Michael <ti...@zzZZzz.net> on 2004/07/02 15:36:22 UTC

a "proper" backup tool

I've been reading a discussion about a "proper" backup tool and now I'm
wondering if I misunderstand something in the nature of svn... Can
someone explain what is wrong with this backup policy... Say, I want to
keep a copy of repository. To make it harder -- remote one. Isn't it
achieved with something like

RREV="`ssh user@host "svnlook youngest /repo"`"
REV="`svnlook youngest /repo`"
if [ "${REV}" != "${RREV}" ] ; then
 REV="`expr ${REV} + 1`"
 ssh user@host "svnadmin dump /repo -r ${REV}:HEAD --incremental" \
 | svnadmin load /repo
fi

Well, of course, one can add conditional creation of the local repo,
more error checking would make sense, maybe, setting umasks if needed,
and even compression filter, but those are unnecessary details.

Wouldn't this pattern get you a proper copy of the repository?

Regards,
 Michael

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: a "proper" backup tool

Posted by Andy Whitcroft <ap...@shadowen.org>.
--On 02 July 2004 17:36 +0200 Michael <ti...@zzZZzz.net> wrote:

> I've been reading a discussion about a "proper" backup tool and now I'm
> wondering if I misunderstand something in the nature of svn... Can
> someone explain what is wrong with this backup policy... Say, I want to
> keep a copy of repository. To make it harder -- remote one. Isn't it
> achieved with something like
> 
> RREV="`ssh user@host "svnlook youngest /repo"`"
> REV="`svnlook youngest /repo`"
> if [ "${REV}" != "${RREV}" ] ; then
>  REV="`expr ${REV} + 1`"
>  ssh user@host "svnadmin dump /repo -r ${REV}:HEAD --incremental" \
>  | svnadmin load /repo
> fi
> 
> Well, of course, one can add conditional creation of the local repo,
> more error checking would make sense, maybe, setting umasks if needed,
> and even compression filter, but those are unnecessary details.
> 
> Wouldn't this pattern get you a proper copy of the repository?

If you want a valid and accessible copy, what about svn-push
(contrib/client-side/svn-push).  That does the same thing essentially?

-apw

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: a "proper" backup tool

Posted by kf...@collab.net.
Michael <ti...@zzZZzz.net> writes:
> I've been reading a discussion about a "proper" backup tool and now I'm
> wondering if I misunderstand something in the nature of svn... Can
> someone explain what is wrong with this backup policy... Say, I want to
> keep a copy of repository. To make it harder -- remote one. Isn't it
> achieved with something like
> 
> RREV="`ssh user@host "svnlook youngest /repo"`"
> REV="`svnlook youngest /repo`"
> if [ "${REV}" != "${RREV}" ] ; then
>  REV="`expr ${REV} + 1`"
>  ssh user@host "svnadmin dump /repo -r ${REV}:HEAD --incremental" \
>  | svnadmin load /repo
> fi
> 
> Well, of course, one can add conditional creation of the local repo,
> more error checking would make sense, maybe, setting umasks if needed,
> and even compression filter, but those are unnecessary details.
> 
> Wouldn't this pattern get you a proper copy of the repository?

(Note that I've rethreaded this to users@.)

This should work fine.  Of course, watch out that the user has the
exact right permissions for that repository, otherwise it's easy for
things to get messed up.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org