Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

svnadmin: Svndiff contains a too large window

Tags:

svn

svnadmin

When I am trying to load / restore my SVN repositories, I get the error:

svnadmin: Svndiff contains a too large window

How can I resolve this?

like image 459
prashant Avatar asked Oct 29 '25 09:10

prashant


1 Answers

Since I ran into this today...

There is likely a corrupted revision in your svn repository with the FSFS database.

BACKUP YOUR SVN REPOSITORY.

Determine if your repository is packed/sharded by reading ${REPO}/db/format

[root@chi2 db]# cat format
4
layout linear

If your fsfs database is 'layout sharded' you'll need to obtain fsfs-reshard.py from here: http://ymartin59.free.fr/wordpress/wp-content/2010/07/fsfs-reshard.py

(This is version works on 1.6+ greater repositories and this guy's patch still hasn't been ported to svn trunk).

Run the following to unpack the repository:

./fsfs-reshard.py ${REPO} 0

Run verify:

svnadmin verify ${REPO}

* Verified revision 13689.
* Verified revision 13690.
* Verified revision 13691.
svnadmin: E185001: Svndiff contains a too-large window

The revision that was errored out was the revision 1 greater than the last verified revision, our bad rev is 13692.

Obtain fsfsverify.py from Subversion trunk. http://svn.apache.org/repos/asf/subversion/trunk/contrib/server-side/fsfsverify.py

Run fsfsverify.py on your bad revision. You may need to run the -f option two or more times. This will spit out a lot of data but eventually it should come clean.

[root@chi2 archive]# ./fsfsverify.py -f ${REPO}/db/revs/13692
Copy 4640123 bytes from offset 1006867
Write 4640123 bytes at offset 1003542
Fixed? :-)  Re-run fsfsverify without the -f option
[root@chi2 archive]# ./fsfsverify.py ${REPO}/db/revs/13692

Run svnadmin verify again. Repeat above process for any further bad revisions.

Once you have a verified repository, you can repack by running

./fsfs-reshard.py ${REPO} 1000

Run svnadmin verify yet again!

Your SVN Repository should be OK!

like image 89
Electrawn Avatar answered Oct 31 '25 13:10

Electrawn