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

occational repository errors using language bindings

From: Todd W <trwww_at_sbcglobal.net>
Date: 2005-06-01 21:46:52 CEST

I use subversion in my application. I access the repository through the perl
bindings. This all works great... sometimes. I've went to revision 950 in
two weeks. Probably 4 times now, I get errors from subversion that look
mostly like this:

Couldn't open a repository: Unable to open an ra_local session to URL:
Unable to open repository
'file:///usr/local/repos/articles/trunk/1115733188': Berkeley DB error
while opening 'uuids' table for filesystem /usr/local/repos/db:
Cannot allocate memory: bdb: Lock table is out of available locker entries
at /usr/local/newsdesk/lib/perl/News/Article.pm line 106

This is the method containing line 106:

sub content {
  my( $self, $revision ) = @_;
  $revision = (defined($revision) && ($revision ne '')) ? $revision :
'HEAD';
  my $ctx = SVN::Client->new();
  my $file = IO::Scalar->new();
  $ctx->cat($file, $self->filepath, $revision); # 106
  return( $file );
}

This is where I use the "svn cat" equivalent. All accesses to the repository
are made with the file: protocol. The error is not always the same, but I
dont have other samples to send.

In this class, I do $ctx->add()s and and $ctx->delete()s, all followed by a
$ctx->commit, and some log browsing.

A "$ svnadmin recover /path/to/repos" always gets me going again, but
obviously I'd like it to never happen.

Since the failures are intermittent, the only thing I can think of is db
corruption because of concurrent accesses (its a multi user system).

Is this what others would guess that the problem is?

If so, could I have sucess moving the $ctx->commit()s to a cron job that ran
every 5 minutes?

My problem with this is what happens when the application does subversion
reads while the cron job is commiting? Won't I be right back where I
started?

[root@host articles]# rpm -qa | grep 'subversion'
subversion-devel-1.1.4-0.1.1.fc2.rf
subversion-1.1.4-0.1.1.fc2.rf
subversion-perl-1.1.4-0.1.1.fc2.rf

Thank you for your time, Any advice is very much appreciated.

Todd W.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Jun 1 21:47:48 2005

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

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