The real answer is "read Stefan's script and do whatever it does".

The core is this:

        ### equivalent to: for ($revision = 1; $revision <= $head_rev; 
$revision++)
        for revision in `$_seq $head_rev`
        do
                if [ -n "$shards" ]
                then
                        shard_dir="`expr $revision / $shards`"
                else
                        shard_dir=""
                fi

                if [ -f "$repository/db/revs/${shard_dir}.pack" ]
                then
                        echo -n "Repository $repository has packing enabled "
                        echo "but fsfsverify.py does not support packed FSFS "
                        echo "repositories - skipping"
                        break
                fi

                echo -n "Checking $repository r${revision}: "
                fsfsverify.py "$repository/db/revs/$shard_dir/$revision" 
>/dev/null
                if [ "$?" != "0" ]
                then
                        echo "BAD"
                        bad_revs="$bad_revs $revision"
                else
                        echo "ok"
                fi

        done


So (more below):

Patrick Fletcher wrote on Wed, Sep 08, 2010 at 11:49:58 -0400:
> Thanks Daniel. Please verify:
> 
> - call fsfsverify.py with no flags set for every single revision
> iteratively?
> 
> >>> fsfsverify.py [repo]/db/revs/[?]/[?]
> 

Yes.

> What kind of output to expect? Is a verbose process or can I just watch for
> any output?
> 

Ignore stdout.  If there is anything on stderr, I suppose you can post
it here.  (As long as the output contains only offsets and checksums,
there is no confidentiality issue in posting it here.)

> If corruption is found from output, do I run on single revision with -f flag
> or reply to thread with results? What are other flags (can't find
> documentation and may be missing something obvious)?
> 

As the script stands, it's "post back to the thread".  The -f flag is
the "attempt to fix" flag.

> Thanks again.
> 
> Patrick Fletcher
> Marquis Software Development
> Business Phone: (850) 877-8864 x132
> Business Fax: (850) 877-0359
> 
> 
> -----Original Message-----
> From: Daniel Shahaf [mailto:d...@daniel.shahaf.name] 
> Sent: Wednesday, September 08, 2010 10:17 AM
> To: Patrick Fletcher
> Cc: 'Stefan Sperling'; 'Tony Sweeney'; users@subversion.apache.org
> Subject: Re: Subversion encountered a serious problem - during svn update
> 
> Just write a loop in some language that does
> 
>       for (i = 0; i <= HEAD; i++)
>               call(fsfsverify, i);
>  
> Patrick Fletcher wrote on Tue, Sep 07, 2010 at 16:43:02 -0400:
> > I see. I have no idea which revisions are problematic as a whole, I have
> > only run into specific cases, of which the only way I could get around and
> > continue working was to dump working copy and checkout HEAD again. 
> > 
> > Only reason cygwin came into picture was to run the .sh file.
> > 
> > I have already run and the normal svnadmin verify which says everything is
> > fine... Still trying to pinpoint where and what the actual problem is. The
> > info in the first email was just to try to help. I have no idea what the
> > actual problem could be. I believe you said this was a more thorough
> > examination (may turn up things svnadmin verify will not). Can I command
> > line the fsfsverify.py to check every revision? If not, can I just write
> > something to do it for me iteratively... Obviously don't want to fix (-f)
> > anything yet as I don't know where the problem lies, but I can find no
> > explanation of the other flags available and I am python nub.
> > 
> > Thanks for bearing with me!
> > 
> > Patrick Fletcher
> > Marquis Software Development
> > Business Phone: (850) 877-8864 x132
> > Business Fax: (850) 877-0359
> > 
> > 
> > -----Original Message-----
> > From: Stefan Sperling [mailto:s...@elego.de] 
> > Sent: Tuesday, September 07, 2010 4:30 PM
> > To: Patrick Fletcher
> > Cc: Tony Sweeney; users@subversion.apache.org
> > Subject: Re: Subversion encountered a serious problem - during svn update
> > 
> > On Tue, Sep 07, 2010 at 03:09:15PM -0400, Patrick Fletcher wrote:
> > > Ahh... Thanks a bunch. The Python file indeed had similar errors. Now
> when
> > I
> > > run I get:
> > > 
> > > ****************************************************
> > > patri...@desk28 /cygdrive/g/Subversion
> > > $ ./verify-revisions.sh Repositories/eomis_1_6_12
> > > /usr/bin/seq: invalid floating point argument: 93909
> > > Try `/usr/bin/seq --help' for more information.
> > > ****************************************************
> > > 
> > > 93909 is HEAD revision. Any ideas?
> > 
> > I'm not a windows expert so the script may fail on cygwin.
> > I've tested it on Linux and BSD.
> > 
> > But if you already know which revisions are problematic, you don't need
> > my script. Just run fsfsverify.py on the problematic revisions directly.
> > For instance: fsfsverify.py /path/to/repos/db/revs/0/42
> > 
> > Stefan
> > 
> > 
> 
> 

Reply via email to