You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Albert Shih <sh...@math.jussieu.fr> on 2005/06/13 11:22:48 UTC
How you backup ?
Hi all,
I want known how you make a backup for your repository ?
I've find two methods (categorie of) :
1/ Something like svnadmin dump > dump; scp dump backup_host in a
crontab
2/ Use some perl/python script to make synchronisation between two
repository, one for using and another for backup.
Suppose I don't have any restriction (I don't care to turn off during
backup my repository, etc...) What's best method to do backup ? I mean,
what's most robust, most portable method to do backup.
Lots of thanks.
--
Albert SHIH
Universite de Paris 7 (Denis DIDEROT)
U.F.R. de Mathematiques.
Heure local/Local time:
Mon Jun 13 13:19:22 CEST 2005
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Proniewski Patrick <pa...@univ-lyon2.fr>.
On 13 juin 05, at 15:37, Ulrich Eckhardt wrote:
>>> 1. Use the hotcopy script to make a duplicate of your repository.
>>> 2. 'svnadmin dump' the copy and backup that data - it's the
>>> repository's content.
>>
>> I do "1" on a weekly basis, and "2" on a daily basis.
>
> Wait a second: you make a local copy of your data every week and
> backup that
> local copy every day???
nop, I'm using svn dump every day, and svn hotcopy every week, always
from the real repository.
> Optionally, you can leave the hotcopy around, so you can quickly
> restore a
> state that is at least recent while not current, just in case the
> original
> gets hosed by some catastrophic failure. It is faster than from the
> dumps
> because the configuration is also copied and because you don't have
> to do the
> whole 'svnadmin load'.
sure. by the way, the "current" backup always stays near the
repository after it has been scp'ed to the backup server, and the
hard drive of the server hosting repositories is backed up on a
dedicated hard drive every night.
>> I'm keeping a month of backups on a remote server. I'm paranoid :)
>
> Paranoid? I'd just call this unresponsible, unless you make backups on
> read-only media and store them somewhere off-site.
the backup server use a RAID 50 drive bay, so it's quite safe (on the
hardware front)
once a month every server is backed up on DVD, and their backup HD is
removed for off-site storage
... and so on, I've just talked about svn "dedicated" backup,
everything is under global backup policy beyond the scope of this thread
> Just imagine some virus
on UNIX ?
> that destroys both the repository and the data on the backup
> server... I
> wouldn't want to be the admin having to tell some %BOSS% that one
> month of
> work of a whole team was hosed due to some malware.
we don't code here, we store on SVN only some homemade shell scripts,
config files for our 20 servers, notes and howto's for administration
purposes. The most sensitive data is an encrypted password file. For
a bunch of files used by 2 sysadmins it's a quite paranoid backup
process.
Patrick PRONIEWSKI
--
Administrateur Système - SENTIER - Université Lumière Lyon 2
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Ulrich Eckhardt <ec...@satorlaser.com>.
Proniewski Patrick wrote:
> On 13 juin 05, at 13:59, Ulrich Eckhardt wrote:
> > 1. Use the hotcopy script to make a duplicate of your repository.
> > 2. 'svnadmin dump' the copy and backup that data - it's the
> > repository's
> > content.
>
> I do "1" on a weekly basis, and "2" on a daily basis.
Wait a second: you make a local copy of your data every week and backup that
local copy every day???
No, the idea is to only access the real repository via the hotcopy script.
This hotcopy script is much faster than 'svnadmin dump' and also copies the
files in the right order so you don't have partial commits - something that
could happen with a simple filecopy. Then, you get a repository on which you
perform the real dump operation whos results you back up.
Optionally, you can leave the hotcopy around, so you can quickly restore a
state that is at least recent while not current, just in case the original
gets hosed by some catastrophic failure. It is faster than from the dumps
because the configuration is also copied and because you don't have to do the
whole 'svnadmin load'.
> I'm keeping a month of backups on a remote server. I'm paranoid :)
Paranoid? I'd just call this unresponsible, unless you make backups on
read-only media and store them somewhere off-site. Just imagine some virus
that destroys both the repository and the data on the backup server... I
wouldn't want to be the admin having to tell some %BOSS% that one month of
work of a whole team was hosed due to some malware.
Uli
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Miha Vitorovic <mv...@nil.si>.
We use incremental dumps for daily and weekly backup [keeping separate
counters], weekly being equal to a monthly backup, once a month. The only
difference is, that we keep weekly backup tapes for a month only [and then
they get reused], and we keep monthly backup tapes for a year, and then
they get reused. I decided on dump, because in the event of a server
crash, I want to be able to use the latest release without problems :)
Cheers,
---
Miha Vitorovic
Inženir v tehničnem področju
Customer Support Engineer
NIL Data Communications, Tivolska cesta 48, 1000 Ljubljana, Slovenia
Phone +386 1 4746 500 Fax +386 1 4746 501 http://www.NIL.si
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Proniewski Patrick <pa...@univ-lyon2.fr>.
On 13 juin 05, at 13:59, Ulrich Eckhardt wrote:
> 1. Use the hotcopy script to make a duplicate of your repository.
> 2. 'svnadmin dump' the copy and backup that data - it's the
> repository's
> content.
I do "1" on a weekly basis, and "2" on a daily basis. I'm keeping a
month of backups on a remote server. I'm paranoid :)
Patrick PRONIEWSKI
--
Administrateur Système - SENTIER - Université Lumière Lyon 2
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: dump vs. hotcopy
Posted by Dirk Schenkewitz <sc...@docomolab-euro.com>.
William Nagel wrote:
> On Jun 21, 2005, at 4:19 PM, Dirk Schenkewitz wrote:
>
>> (Sorry, I forgot again *slaps self resends to the list*)
>
>
> Heh. I did the same thing. :-)
:-)
> On Jun 21, 2005, at 4:12 PM, Dirk Schenkewitz wrote:
>
>>
>>> My backup process actually uses both. I use a hotcopy to create a
>>> backup of the entire repository to an onsite backup server, and use
>>> an incremental dump to send all of the changes made since the last
>>> backup to an offsite backup server.
>>>
>>
>> Hmm, why incremental? That means you must keep all previous incremental
>> dumps. Why not full dumps every time and replace/overwrite the previous
>> ones? (Except you burn them on CD every time you have enough data.)
>>
>
> You'll notice that I said it goes to an offsite backup server. Maybe I
> wasn't clear that the data is sent to the offsite server over a
> network. Sending the entire repository every night would be
> prohibitive, but sending only the day's changes is very reasonable
> (given the average daily changes on our repository).
Yes it is - I could have thought of that myself.
> Since n
> incremental dumps aren't appreciatively larger in totality than a
> single all-encompassing dump it really isn't a big deal to keep all of
> the incremental dumps around.
>
> If you really see keeping the incremental dumps around as a problem,
> though, one solution would be to have the backup server automatically
> load the dumps into a local repository as it gets them. Then that
> reconstructed repository could be backed up (or dumped to one big dump
> file).
Maybe transferring the big file via rsync could spare some bandwidth...
> -Bill
Thanks Again
Dirk
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: dump vs. hotcopy
Posted by William Nagel <bi...@stagelogic.com>.
On Jun 21, 2005, at 4:19 PM, Dirk Schenkewitz wrote:
> (Sorry, I forgot again *slaps self resends to the list*)
Heh. I did the same thing. :-)
On Jun 21, 2005, at 4:12 PM, Dirk Schenkewitz wrote:
>
>
>> My backup process actually uses both. I use a hotcopy to create
>> a backup of the entire repository to an onsite backup server, and
>> use an incremental dump to send all of the changes made since the
>> last backup to an offsite backup server.
>>
>>
>
> Hmm, why incremental? That means you must keep all previous
> incremental
> dumps. Why not full dumps every time and replace/overwrite the
> previous
> ones? (Except you burn them on CD every time you have enough data.)
>
You'll notice that I said it goes to an offsite backup server. Maybe
I wasn't clear that the data is sent to the offsite server over a
network. Sending the entire repository every night would be
prohibitive, but sending only the day's changes is very reasonable
(given the average daily changes on our repository). Since n
incremental dumps aren't appreciatively larger in totality than a
single all-encompassing dump it really isn't a big deal to keep all
of the incremental dumps around.
If you really see keeping the incremental dumps around as a problem,
though, one solution would be to have the backup server automatically
load the dumps into a local repository as it gets them. Then that
reconstructed repository could be backed up (or dumped to one big
dump file).
-Bill
>
> Thanks!
> Dirk
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: dump vs. hotcopy
Posted by Dirk Schenkewitz <sc...@docomolab-euro.com>.
(Sorry, I forgot again *slaps self resends to the list*)
William Nagel wrote:
> On Jun 21, 2005, at 12:10 PM, Mark Parker wrote:
>
>>
>> Dirk Schenkewitz wrote:
>>
>>> Are there any special advantages of "dump" compared to "hotcopy",
>>> other than
>>> the ability to make incremental dumps?
>>>
>>
>> The dump could (theoretically) be loaded by any future version of
>> Subversion. The hotcopy (theoretically) needs the correct machine
>> architecture, version of bdb (if it's a bdb repo) and version of
>> Subversion to work.
>>
>> Mark
I see. So for archiving, dump is better, because future versions of
svn should be able to read it and rebuild the repository in their new
"native" format, whatever it might be. Thank you!
> My backup process actually uses both. I use a hotcopy to create a
> backup of the entire repository to an onsite backup server, and use an
> incremental dump to send all of the changes made since the last backup
> to an offsite backup server.
Hmm, why incremental? That means you must keep all previous incremental
dumps. Why not full dumps every time and replace/overwrite the previous
ones? (Except you burn them on CD every time you have enough data.)
Thanks!
Dirk
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: dump vs. hotcopy
Posted by William Nagel <bi...@stagelogic.com>.
On Jun 21, 2005, at 12:10 PM, Mark Parker wrote:
>
> Dirk Schenkewitz wrote:
>
>> Are there any special advantages of "dump" compared to "hotcopy",
>> other than
>> the ability to make incremental dumps?
>>
>
> The dump could (theoretically) be loaded by any future version of
> Subversion. The hotcopy (theoretically) needs the correct machine
> architecture, version of bdb (if it's a bdb repo) and version of
> Subversion to work.
>
> Mark
My backup process actually uses both. I use a hotcopy to create a
backup of the entire repository to an onsite backup server, and use
an incremental dump to send all of the changes made since the last
backup to an offsite backup server.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: dump vs. hotcopy
Posted by Mark Parker <ma...@msdhub.com>.
Dirk Schenkewitz wrote:
> Are there any special advantages of "dump" compared to "hotcopy", other
> than
> the ability to make incremental dumps?
The dump could (theoretically) be loaded by any future version of
Subversion. The hotcopy (theoretically) needs the correct machine
architecture, version of bdb (if it's a bdb repo) and version of
Subversion to work.
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
dump vs. hotcopy
Posted by Dirk Schenkewitz <sc...@docomolab-euro.com>.
Hi,
I just tried something (SVN-1.2.0, FSFS)
---------------------------------
# svnadmin hotcopy AN AN.backup
# svnadmin dump AN.backup > AN.backup.dump
# tar -cvf AN.backup.tar AN.backup
# bzip2 -k AN.backup.dump AN.backup.tar
# ll
...
drwxr-xr-x 7 root root 1024 Jun 21 10:52 AN.backup
-rw-r--r-- 1 root root 4941453 Jun 21 11:49 AN.backup.dump
-rw-r--r-- 1 root root 891698 Jun 21 11:49 AN.backup.dump.bz2
-rw-r--r-- 1 root root 1669120 Jun 21 11:49 AN.backup.tar
-rw-r--r-- 1 root root 840067 Jun 21 11:49 AN.backup.tar.bz2
...
# du -sb AN.backup
1558671 AN.backup
----------------------------------
I'm astonished that the dump is about 3 times the size of the tar-file.
And from what Ulrich Eckhardt wrote:
> 1. Use the hotcopy script to make a duplicate of your repository.
> 2. 'svnadmin dump' the copy and backup that data - it's the repository's
> content.
> 3. If you're really paranoid, backup the configuration data from (the copy of)
> your repository. Which configuration data you have depends on your access
> method, but the contents of the 'conf' subdir are a candidate. You should
> know which those are, you modified them by hand when setting up the
> repository.
I get the impression that 'svnadmin hotcopy' is safer that 'svnadmin dump'
and more complete. For pure backups, it seems to be the better solution.
E.g., do an 'svnadmin hotcopy REPO REPO.bak' from a post_commit-hook if
REPO.bak does not exist, then make a compressed tarfile from REPO.bak and
delete REPO.bak.
Maybe keep the last 5 tar-files and delete the older ones. Maybe send the
tar-files via scp or rsync to some other machine and/or burn them to CD/DVD
if you are paranoid enough (like me).
Ok, this can be done only for repositories that are not too big. For very
big repositories it might be better to create incremental dumps, but the
disadvantage is that you need to keep all of them to be able to fully
restore a repository, and they seem to take a little more space than one
dump of the whole repository.
Are there any special advantages of "dump" compared to "hotcopy", other than
the ability to make incremental dumps?
Best regards
Dirk
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Ulrich Eckhardt <ec...@satorlaser.com>.
Albert Shih wrote:
> Suppose I don't have any restriction (I don't care to turn off during
> backup my repository, etc...) What's best method to do backup ? I mean,
> what's most robust, most portable method to do backup.
1. Use the hotcopy script to make a duplicate of your repository.
2. 'svnadmin dump' the copy and backup that data - it's the repository's
content.
3. If you're really paranoid, backup the configuration data from (the copy of)
your repository. Which configuration data you have depends on your access
method, but the contents of the 'conf' subdir are a candidate. You should
know which those are, you modified them by hand when setting up the
repository.
Uli
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Shib SS <sh...@yahoo.co.in>.
Can also use hot-backup.py script. More help at
http://svnbook.red-bean.com/en/1.1/ch05s03.html#svn-ch-5-sect-3.6
_______________________________________________________
Too much spam in your inbox? Yahoo! Mail gives you the best spam protection for FREE! http://in.mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: How you backup ?
Posted by Martin Probst <ma...@x-hive.com>.
Hi,
> I've find two methods (categorie of) :
>
> 1/ Something like svnadmin dump > dump; scp dump backup_host in a
> crontab
>
> 2/ Use some perl/python script to make synchronisation between two
> repository, one for using and another for backup.
there is also "svnadmin hotcopy". We currently use that (create a live
copy of the repository, tar & scp). I had the impression it's faster
than "svnadmin dump" and deploying the backup is also easy and fast -
just copy the backup to the correct location.
Regards,
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org