5

I cannot figure out why I get this error during check-in. I checked in successful only a few hours ago so not sure why now it's complaining

Error: Commit failed (details follow):  
Error: Checksum mismatch for   
Error: 'C:\sss\sss\trunk\xxxx\.svn\text-base\Header.ascx.svn-base'; expected:   
Error: '3cee96f580409a1711a47541a07860dd', actual: 'a5fc0f8819b88bf32ab38d4c9a6b0654'  
Error: Try a 'Cleanup'. If that doesn't work you need to do a fresh checkout.  

I got latest and also performed a clean-up which said successful so not sure what else to do.

PositiveGuy
  • 46,620
  • 110
  • 305
  • 471

5 Answers5

10

Something has gotten out of sync or has become corrupt, and because it's in your .svn BASE directory, unless you are confident tinkering with this, you're probably better off deleting the parent of the .svn directory and then perform an update. Of course, take a backup or see if an export works before doing this, so you don't lose any changes.

FWIW, I get this sometimes with our library references where Visual Studio seems to keep a lock on some files (even though it's not compiling) and won't let me update them. I believe this is related to the xml documentation files.

Note: Subversion 1.7+ implements a new working copy approach which centralises the meta data, and it now has a single .svn directory at the root of your working copy. Your best bet is a cleanup, failing that a fresh checkout into another directory and export or file copy the corrupted working copy except for the .svn directory, over to the fresh checkout, and commit any local changes.

si618
  • 16,580
  • 12
  • 67
  • 84
  • so you're saying delete the parent .svn folder? – PositiveGuy Jul 21 '09 at 13:37
  • I deleted my parent .svn, but then you lose the update command in your context menu..? – PositiveGuy Jul 21 '09 at 14:01
  • >Also, I gather xxxx.svn has had it's name changed for SO, because normally it's just .svn. It was a posting issue, I wrapped the error above in code tags which renders the real error as I saw it – PositiveGuy Jul 21 '09 at 16:45
  • Sorry if I wasn't clear; I assumed the problem wasn't at the root of your working copy, thus your parent directory itself has a .svn directory (which knows about it), which means an svn update would pull down a fresh version of the directory and its contents. If it was at root, then yes, I'm afraid a complete new checkout would be required. – si618 Jul 22 '09 at 00:10
  • the single .svn folder on subversion 1.7 is not cool at all. when a cleanup dont work , the only solution seems to be the fresh checkout, but when you have a repository with 100.000 + files and 100+ Go it s really boring to do that. – Nico AD Sep 16 '13 at 13:20
3

Looks like one of your SVN files is corrupt. First, check-in everything that can safely be checked in, and make sure to backup everything. Then fix the offending file - usually this involves deleting it from your repository. This should be okay if you're checking in a new version anyway.

bkritzer
  • 1,418
  • 3
  • 16
  • 27
  • 1
    Are you sure you need to delete it from the repository? It looks like just the working copy is corrupt. Also, the file is the BASE copy in .svn, normally you don't want to mess around with this directory. – si618 Jul 20 '09 at 23:20
  • but how can I check in when it's an atomic commit when you commit at the base? – PositiveGuy Jul 21 '09 at 13:36
  • 1
    Another thought: have you tried saving your working copy and reverting to the previous revision (the one before head), then re-committing your working copy? – bkritzer Jul 21 '09 at 15:33
  • Yes, but you can back up your working copy before reverting, then replace it after the revert. – bkritzer Jul 21 '09 at 18:56
  • well, good thing I don't have too many updates then to merge back or else that would be a nightmare. – PositiveGuy Jul 21 '09 at 19:24
0

I received a similar error after our project repository was moved to a new server. Try reverting your file and reapplying your changes.

user735232
  • 181
  • 2
  • 6
  • I was in the same situation (repo moved to a new server) and tried this but it didn't work. I had to delete the offending file from the repo and add it again. – kmoser Jan 18 '17 at 18:25
0

I had same problem after googling for some help found articles that suggested to override the checksum in the .svn\entries file. But in that file the checksum was actually as the the expected one in the error message.

To fix the problem, I navigated to .svn\text-base dir of problem file's directory and found out that there's a copy of the file i was trying to check in changes for. I opened that file in Notepad++ and replaced it's content with content of the file to be commited and i was able to commit afterwards.

But just in case, make a backup copy of the .svn\text-base file. I think this happened because i did an svn update before commit because it complained that my version is outdated. Anyway, it's fixed for me and hope my solution helps someone else too.

devOp
  • 3,150
  • 1
  • 18
  • 32
0

With Tortoise SVN, I choose to delete the file in Repo Browser.

First back up the problem file. and use Repo Browser delete the problem file in it, then update local folder so the file in local folder is deleted. Then copy back the backup file and Add > Commit, then I can update successfully.

The disadvantage of this method is the history of this file will be removed.

Also see another post.

yu yang Jian
  • 6,680
  • 7
  • 55
  • 80