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

repository corrupted repeatedly

From: Will Glass-Husain <wglass_at_forio.com>
Date: 2005-09-28 21:27:17 CEST

Hi,

I'm having trouble with a repeatedly corrupting repository. I've searched the mailing list and issues tracker haven't got any insights.

Setup: Linux (Suse 9.2) with Subversion 1.0.8, Apache 2.0.49, Berkeley DB 4.2. I haven't updated Subversion since I can't seem to find a later Suse RPM. (I may try compiling if I get desperate).

The problem. Three times in the past few days my (recently created) repository has become corrupted. Symptoms:

(1)
svn command line:

$ svn log
svn: PROPFIND request failed on '/svn/src1/loyalty/trunk'
svn: PROPFIND of '/svn/src1/loyalty/trunk': 500 Internal Server Error (https://www.dynamicsymmetry.symmetrics.com)

(2)
$ svnlook log /var/svn/src1

svn: Berkeley DB error while checkpointing after Berkeley DB transaction for filesystem /var/svn/src1/db: Invalid argument
svn: Berkeley DB error while closing 'nodes' database for filesystem /var/svn/src1/db: Invalid argument

(3)
A number of the "db" files ownership have been mysteriously changed from "wwwrun" to "root". Changing them back does not help.

(4)
Apache Log (date/time/ip omitted)

... (2)No such file or directory: cannot access type map file: HTTP_UNAUTHORIZED.htm
... Could not fetch resource information. [500, #0]
... Could not determine the proper revision to access [500, #160029]
... Berkeley DB error while checkpointing after Berkeley DB transaction for filesystem /var/svn/src1/db:\nInvalid argument [500, #160029]
... (20014)Error string not specified yet: Berkeley DB error while closing 'nodes' database for filesystem /var/svn/src1/db:\nInvalid argument

The Fix:

The last time I had this issue I recovered the database, then changed the permissions to be readable by the apache2 user.

$ su
$ cd /var/svn/src1/db
$ db_recovery -e -v
$ chown -R wwwrun .

This worked. The next time this happened it failed:

$ cd /var/svn/src1/db
$ db_recovery -e -v

db_recover: Finding last valid log LSN: file: 68 offset 102818
db_recover: Ignoring log file: log.0000000065: magic number 0, not 40988
db_recover: Invalid log file: log.0000000065: Invalid argument
db_recover: First log record not found
db_recover: PANIC: Invalid argument
db_recover: DB_ENV->open: DB_RUNRECOVERY: Fatal error, run database recovery

Any tips for where I should investigate further? Or should I just grit my teeth and compile the latest subversion (scrapping the Suse RPM system).

Thanks, WILL
Received on Wed Sep 28 21:29:44 2005

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