Krishna
Krishna

Reputation: 473

SVN file locked by me, now cannot commit it

Scenario: An binary file needs a svn lock to modify. To modify, the file was first locked, modified, and then while committing, cancelled the commit using the "Cancel" button. Due to some reason, deleted the whole folder containing the locked file (including the .svn folder).

Problem: I used "SVN update" through tortoise svn. All the files were updated. But the file which was locked previously does not indicate as locked with the lock symbol. Nevertheless, I modified the file and tried to commit.

Error while committing:

 Server sent unexpected return value (423 Locked) in response to PUT request for '/****/!svn/wrk/9f89b6b6-7932-9f45-82e8-fafbd5426290/trunk/***'

While I try to acquire the lock again using "SVN Get Lock" it fails showing:

Error when trying to acquire the lock:

.`...is already locked by user 'kr***' in filesystem '/data/svn/dir/***/repos/***/db'`

What I feel, is that the lock information on the client side is missing but still present on the server side.

Please suggest a way out.

Version info: TortoiseSVN 1.6.8, Build 19260 - 32 Bit , 2010/04/16 20:20:11

NOTE: Few paths and logins are masked using *

Upvotes: 26

Views: 46813

Answers (4)

Cory Danielson
Cory Danielson

Reputation: 14501

In the terminal,

svn cleanup 

will break the locks.

Upvotes: 2

user244343
user244343

Reputation:

According to Simon Large (co-author of TortoiseSVN):

Use the repo browser and 'break lock' from the context menu.

Screenshot:

TortoiseSVN 'Break lock' command

Note that this item will only appear if the item is, in fact, locked. There's also a 'Release lock...' command outside of the repo browser, shown here:

TortoiseSVN 'Release lock...' command

Upvotes: 36

toddmo
toddmo

Reputation: 22416

A Clean up on the working copy root fixed the issue for me. I, too, had done a Cancel while doing a SVN Commit.

Upvotes: 25

Chandu
Chandu

Reputation: 75

Sometimes back I was using the SVN, You can take a fresh checkout and then merge your changes on that file. Once you merge it you can commit the file to SVN.

Upvotes: 0

Related Questions