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

Re: Berkeley DB error due to hardware problem

From: Max Bowsher <maxb_at_ukf.net>
Date: 2004-07-13 11:01:14 CEST

Matthias Neubauer wrote:
> Hello,
>
> probabaly due to hardware problems of our (former) repository hard
> disk, one of our Subversion repositories seems to be corrupted right
> now. This is situation right now: Running "svnadmin recover" runs
> without any errors/complaints. However, a subsequent "commit" or
> running "svnadmin verify" still leads to the following Berkeley DB
> error:
>
> Apache:
>
> [Mon Jul 12 16:35:07 2004] [error] [client 132.230.151.5] (17)File
> exists: Berkeley DB error while moving cursor for filesystem
> /export/server/subversion/proglang/db:\nDB_PAGE_NOTFOUND: Requested page
> not found [500, #160029]
>
> SVN:
>
> # svnadmin verify /export/server/subversion/proglang
> * Verified revision 0.
> * Verified revision 1.
> svn: Berkeley DB error while moving cursor for filesystem
> /export/server/subversion/proglang/db:
> DB_PAGE_NOTFOUND: Requested page not found
>
> Also, dumping parts of the repository (using revision number ranges)
> seems to show that errors occur approximately every hundred or so
> revision numbers.
>
> Does anybody now how to deal with this specific Berkely DB error?
>
> We've got a backup of the repository from a couple of days back
> without errors. Is there common "emercency strategy" how to proceed in
> such situations?

Restore the backup

Attempt a "svnadmin dump --incremental -r <first revision not in
backup>:HEAD /broken/repos"

If this completes fine, just load the dump into the restored backup, and
everything is restored.

If not, you may be able to recover missing revisions from archived commit
emails.

Another possibility is to attempt to recover the BDB database:

db_recover -cv #(in the repos/db subdir)

Or, if you have a complete set of db logs from the time of last backup
forward, you can try copying the logs (including the one with the number of
the file present in the backup, because it was probably updated after the
backup was made) from the broken repos to copy of the backup. Then try the d
b_recover -cv in the restored backup.

Max.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Jul 13 11:05:55 2004

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