Proposal for svnadmin copy command
From: Vladimir Berezniker <vmpn_at_tigris.org>
Date: 2003-08-13 20:03:37 CEST
I. Purpose
II. Hot-backup.py
The following algorithm is employed, to do backups:
Step 1: Get youngest revision. If revision exists find largest available
Step2: Copy the whole repository.
Step3: Recopy all Berkeley log files.
Step4: Recover the copy repository.
Step5: Check if lock file (specific to hot-backup.py) exists, if so then quit.
Step6: In the original repository remove all unused log files.
Step7: Remove lock.
Step8: Delete all but the newest N backups.
III. Concerns regarding Hot-backup.py
Between Step2 and Step3 log files are copied twice. If one were to copy
In Step6 there is a potential for a log file to be deleted before it was
> I have a concern about unconditionally deleting unused log files in the
IV. New svnadmin copy command
1a. (Source) Acquire shared lock on db.lock. Indicates that we working with db env.
1b. (Source) Acquire shared (no log archiving) or exclusive (log archiving) lock
2. (Source -> Copy) Copy repository recursively with the following exceptions:
locks - Do not copy locks, recreate them. E.g lock file could be locked
dav - Do not copy, transient information (please correct me, if my
3a. (Copy) Recreate locks directory.
3b. (Copy) Acquire exclusive lock on db.lock.
4a. (Copy) Recreate db directory.
4b. (Source -> Copy) Copy tables.
4c. (Source -> Copy) Copy all logs files.
4d. (Copy) Run recovery on the copy.
4e. (Source) Optionally delete unused log files from source repository that are
5a. (Source) Release dblogs.lock
5b. (Source) Release db.lock
5c. (Copy) Release db.lock
Sincerely,
---------------------------------------------------------------------
|
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.