Build fails while checking for changes in Starteam for a project

I have a project in Starteam that contains over 49,000 source files. I get the out of memory error when I attempt to do a build on that project.
The error occurs after about 2 hours of "Checking for changes". The memory setting on the server is  shown below:

Teamcity Server memory settings:  -Xms512m -Xmx512m -XX:PermSize=128m -XX:MaxPermSize=256m

Firstly is the memory issue Teamcity server related or is it agent related? It seems apparent that it is server side related
since the error occurs while checking for changes. The memory settings on the agents is shown below:

TEAMCITY_AGENT_MEM_OPTS='-Xms512m -Xmx1024m -XX:MaxPermSize=256m'

If the issue is a teamcity server issue, why would the server run out of memory checking for changes?

Unable to collect changes
java.util.concurrent.ExecutionException:  jetbrains.buildServer.vcs.VcsException: Problem collecting changes for  'PMS :: PMS Rehosting Production Configuration' : Error collecting  changes for VCS root 'PMS Rehosting VCS Root'
java.lang.OutOfMemoryError: GC overhead limit exceeded
at java.util.concurrent.FutureTask$Sync.innerGet(
at java.util.concurrent.FutureTask.get(
at jetbrains.buildServer.serverSide.impl.CancelableTaskHolder.waitForTaskToComplete(
at  jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl.doCollectChanges(
at jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl.access$000(
at jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl$
at jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl$
at jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl$
at jetbrains.buildServer.serverSide.impl.auth.SecurityContextImpl.runAs(
at jetbrains.buildServer.serverSide.impl.auth.SecurityContextImpl.runAsSystem(
at  jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl.runAsSystem(
at  jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl.collectChangesForGraph(
at  jetbrains.buildServer.serverSide.impl.dependency.TopBuildDependencyGraphImpl.collectChangesForGraph(
at jetbrains.buildServer.serverSide.impl.BuildChangesCollector.collectChangesForBuild(
at jetbrains.buildServer.serverSide.impl.BuildStarter$
at java.util.concurrent.Executors$
at java.util.concurrent.FutureTask$Sync.innerRun(
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
at java.util.concurrent.ThreadPoolExecutor$

1 comment
Comment actions Permalink

It seems the error occurs on the server side. Please try to obtain memory dump. If you run TeamCity server under the JVM 1.6 you can take memory dump from the Administration -> Server Configuration -> Diagnostics page. Another way is to start server with additional JVM argument: -XX:+HeapDumpOnOutOfMemoryError In case of out of memory error an *.hprof file must be created in the server working directory (usually this is bin directory). Please upload this hprof to our FTP: and send us name of the file.


Please sign in to leave a comment.