I am facing a problem recently with my CI environment.
I am using Hudson ver. 1.395.1 and SVN ver 1.4.2.
My Hudson is continuously polling the SVN for any changes, and if so it kicks off a build.
Recently this operation fails with the below message
Updating https://MY_SVN_URL/trunk
Workspace appear to be locked, so getting a fresh workspace
Checking out https:/MY_SVN_URL/trunk
ERROR: Failed to check out https://MY_SVN_URL/trunk
org.tmatesoft.svn.core.SVNException: svn: Working copy '/Hudson/workspace/MY_PROJECT_NAME' locked; try performing 'cleanup'
It has to be noted that this only happens when i commit changes and Hudson is trying to trigger a build (by polling the SVN). The problem does not happen when i manually trigger the build.
It seems to me that the polling is locking the Hudson workspace and the update operation is finding the workspace locked.
Has anyone been to the same situation before? Any solutions to this?
Thanks.
I would answer my own question, as this maybe useful for other people.
The root cause of this, was actually something very simple. The server that Hudson runs on, was rebooted 3-4 days prior to this incident.
It was found out, that two instances of Hudson were running on the machine. So one instance was acquiring and holding lock making the other to fail intermmitently.
Funny thing is that despite the server re-started 3 days ago, the problem came up today.
So just for further reference if someone ever faces this kind of a problem better check first the above simple thing, before spending too much time like me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With