Build agent high disk activity

We installed TeamCity build agent on a target computer that runs our medical software. The purpose is to have automated smoke tests run on that computer. However, every now and then, it looks like TeamCity produces high disk activity, interfering with the execution of our software and error conditions that cause the smoke test to fail.

Are there options to make the TeamCity agent service not compete for resources until when the build is complete?

1 comment
Comment actions Permalink
Hello,
First I would recommend you to check the build logs when these situations occur, and check the agent machine resources (CPU, disk, memory, network) during a build to identify any possible bottleneck and which processes are causing it.
 
You should consider that it is very rare that the build agent process itself is causing resource hogs, as they are usually very light processes. The agent typically is just in charge of picking up the build settings, setting up the build, and starting it: it is typically the builds that cause  resource hogs. However it can happen that the agent has some heavy I/O usage since it is the agent process which cleans up the folders before and after builds.
 
With that in mind, if you find that the build agent is causing the issues (that is very rare as explained above), you can check the Agent Properties and try to set -XmsNNNm -XmxNNNm -XX:MaxPermSize=NNNm in TEAMCITY_AGENT_MEM_OPTS (please replace the NNN for appropriate values that make sense in your target computer). Please be also aware that by doing this you might run into OutOfMemory errors if the memory limits that you set are too low.
 
It might be possible also that adjusting some OS settings or applying quotas to the resources the processes are allowed to run can help to avoid this situation.
 
Please let me know if you have any more questions.
 
Guilherme
 
 
 
 
 
 
 
0

Please sign in to leave a comment.