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

Re: New file svn-restore-dumps.py

From: masaru tsuchiyama <m.tmatma_at_gmail.com>
Date: Tue, 10 Mar 2009 22:07:51 +0900

Hi

> If there are no dump files at all in the nominated dump directory.
> If the repository is a later revision than all dump files.
> (your test) If it detects there are later dump files but the required
> incremental dumps are missing.
It works fine in these three senarios and in (of cource) an ordinary senario

Regards.
Masaru.

2009/3/10 Mark Stead <mark_at_stead.id.au>:
> Thanks for your feedback.
>
> I've made error checking enhancements and clearly this is an error condition
> that should be detected.
> It will now complain:
>
> If there are no dump files at all in the nominated dump directory.
> If the repository is a later revision than all dump files.
> (your test) If it detects there are later dump files but the required
> incremental dumps are missing.
>
> I've also removed an unused function (get_last_dump_rev) that was copied
> across from my changes to svn-backup-dumps.py.
>
>
> So just to clarify on the usage.  The script does not require dumps going
> back to revision 0.  It only requires dumps from the youngest + 1.
>
> Note the "-c" mode of svn-backup-dumps.py will create valid input - but does
> create more files than necessary - for example you might get:
> dump 100-120
> dump 100-130
> dump 100-145
> Where the older dumps (e.g. 100-120) are not removed, this restore script
> should automatically use the 100-145 dump to get to the highest revision.
> If you had restored using the 100-120, then you couldn't use the 100-145
> dump (without manual editing of the dump file).
>
> This is why I wrote an extension for svn-backup-dumps.py which will now
> support "relative incremental" mode (-i).  In this mode, you would have the
> dumps created as:
> dump 100-120
> dump 121-130
> dump 131-145
>
> You can get the new version of svn-backup-dumps.py here:
> http://svn.collab.net/repos/svn/trunk/tools/server-side/svn-backup-dumps.py
>
> I've attached a new revision of svn-restore-dumps.py, plus the diffs against
> the previous version.
>
>
> Also, just to clarify why I've done this.  I'm using these scripts to
> perform incremental backup - and keep my home & work repository up-to-date.
>
>
> 2009/3/10 masaru tsuchiyama <m.tmatma_at_gmail.com>
>>
>> Hi
>>
>> I have tried this script.
>>
>> Is this intented?
>>
>> 1. Create backup files by svn-backup-dumps.py
>> svn-backup-dumps.py -b -c 100 c:\svnrepos c:\backupdir
>>
>> 2. Delete first dump file to emulate the situation when one of dump
>> files is missing.
>> del svnrepos.000000-000099.svndmp.bz2
>>
>> 3. Try to restore from the dumps.
>> svn-restore-dumps.py -c c:\testtest\svnrepos c:\backupdir
>>
>> In step3, the output is "Everything OK" and the script do nothing.
>>
>> Regards.
>> Masaru
>>
>>
>>
>>
>>
>>
>> 2009/3/9 Mark Stead <mark_at_stead.id.au>:
>> > Hi, I've created a new utility called svn-restore-dumps.py.  It is
>> > intended
>> > to be used with dumps created by svn-backup-dumps.py.
>> >
>> >
>> > [[[
>> > Add svn-restore-dumps.py, a tool to import dump files created by
>> > svn-backup-dumps.py.
>> >
>> > * tools/server-side/svn-restore-dumps.py: New file.
>> > ]]]
>> >
>
>

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1302922
Received on 2009-03-10 14:08:05 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.