2
votes

I tried to dump our SVN repository so I could migrate it to newer hardware. One of the revisions gave me a problem though so I tried to skip or "jump" that revision dumping from that number to a higher revision number but the problem persisted:

svnadmin: Can't read file 'D:\repositories\REPO_NAME\db\revs\3677': End of file found

Thing is that I executed the following command:

svnadmin dump D:\repositories\REPO_NAME --revision 4000:5000 > D:\4000_5000.dmp

So that's supposed to dump only revision 4000 to 5000 but it happens that for some reason that revision range do deppend uppon the lower revision.

So I went to the db/revs directory to see what happened to the conflicting file and the file was empty, zero bytes.

I looked through all the "SVN red book", SVN documentation and google but find nothing, there are many examples of recovering the repository but none of them worked, for exmaple, running svnadmin recover throws another error:

"An attempt was made to move the file pointer vefore the beginning of the file"

So I'm a little bit lost now, Is there any way to recover an empty file or exclude it from the dump so it does not affect highe revisions?

1

1 Answers

0
votes

Is there any way to recover an empty file ?

Obviously the answer is no. You have to restore the revision file from your backups.

or exclude it from the dump so it does not affect highe revisions

It is possible to get this working with the --incremental switch:

svn dump D:\repositories\REPO_NAME --incremental --revision 4000:5000 > D:\4000_5000.dmp

However, it will not complain, but you will have problems to assemble your repository with svnadmin load as it will complain some missing nodes(if they were added in rev 3677). But this could give you a clue what happened in revision 3677.