Return-Path: X-Original-To: apmail-subversion-users-archive@minotaur.apache.org Delivered-To: apmail-subversion-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1AB94D326 for ; Wed, 1 Aug 2012 14:50:22 +0000 (UTC) Received: (qmail 57160 invoked by uid 500); 1 Aug 2012 14:50:21 -0000 Delivered-To: apmail-subversion-users-archive@subversion.apache.org Received: (qmail 57133 invoked by uid 500); 1 Aug 2012 14:50:21 -0000 Mailing-List: contact users-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@subversion.apache.org Received: (qmail 57122 invoked by uid 99); 1 Aug 2012 14:50:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Aug 2012 14:50:21 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jcorvel@gmail.com designates 209.85.212.43 as permitted sender) Received: from [209.85.212.43] (HELO mail-vb0-f43.google.com) (209.85.212.43) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Aug 2012 14:50:13 +0000 Received: by vbbfq11 with SMTP id fq11so14923239vbb.16 for ; Wed, 01 Aug 2012 07:49:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=9xQXizij9UH8Aie2IX15yctyU6iO9BWrJ4qtCd0zhI4=; b=SILefIco1Y+0uIYrhKrzgpn3LdEN8iK1gGhUqRv5IZhdGyRtQLctrZEEs+wg+45IUd SFlYAKW3Hd6r2GscG6CXYvozouf1SadCZ7Fan3LMRLracgarl+tWCQ6qdb7oK7l4ITb7 JNTxeIp3VRWL6G8DuBA2EsEMLL03Uz+2QWLJ37gR2pP63sxspDDf/Aql3sNIR+J5idy6 HyMv5WzuQGh6SAJCuHLSH7AoyMOopcyXNJuxJJUQFUZY1aX5TSupIsW6KWYvA82MCQcA JkNxaXgFZ8U5CWtnxRUsMp5WeQ+1Rr87qVVHO6i+5FQnZJEe0NkMu85iwCrRdOivTDJP nvYA== Received: by 10.220.21.80 with SMTP id i16mr17028909vcb.70.1343832592349; Wed, 01 Aug 2012 07:49:52 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.117.139 with HTTP; Wed, 1 Aug 2012 07:49:31 -0700 (PDT) In-Reply-To: References: From: Johan Corveleyn Date: Wed, 1 Aug 2012 16:49:31 +0200 Message-ID: Subject: Re: Repairing or removing broken revisions To: Joachim Sauer Cc: users@subversion.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Aug 1, 2012 at 2:24 PM, Joachim Sauer wrote: > Hello, > > I'm currently reworking backups of multiple SVN repositories. In the > process I found out that one of those repositories has three broken > revisions. The problem is that the revision files in the revs > directory for those 3 revisions are of size 0 (those contain the > actual data of the revision, as far as I understand). This means that > I can't use svn dump (as it stops at that broken revision) and I can't > use svnsync. > > For the backup itself I can still use svn hotcopy (the previous way of > doing a backup), so this will be my workaround. > > I was able to find out the affected paths in the repository and > luckily the latest revision of those paths can be checked out without > a problem (so we "only" lost history, not current data). > > But a broken repository is not desirable and I should attempt to fix > it as much as possible. Losing the information of those three > revisions (and a few related ones, probably) would not be a major > problem, but the repository as a whole should be in a consistent state > (to allow svnadmin dump to work, for example). > > Is there a way to remove the broken revisions and still keep the rest > of the repository intact? Ideally without requiring everyone to make > new clean checkouts because the repository became incompatible. > > regards > Joachim Sauer > > P.S.: unfortunately there are no working backups of the broken > revisions, as the corruption seems to be pretty old (older than our > last full backup). Since you know the affected paths, I think one possible way is to do an svnsync, while excluding the "corrupted paths" by way of path-based authz (i.e. make the affected paths unreadable by the svnsync user, using an authz file on the source repository). After that, re-import the "corrupted files" from one of your working copies. I think everyone will have to re-checkout though, because you'll have a new repository with slightly altered history. So it wouldn't be safe to give this new repository the same repos-uuid, and act like it's the same. If you search the mailinglist archives, you might find some more posts about this svnsync recovery trick (excluding broken files). -- Johan