Install Multiple Agents on the Same Machine

TeamCity treats equally all agents no matter if they are installed on the same or on different machines. However, before installing several TeamCity build agents on the same machine, please consider the following:
* Builds running on such agents should not conflict by any resource (common disk directories, OS processes, OS temp directories).
* Depending on the hardware and the builds you may experience degraded builds’ performance. Ensure there are no disk, memory, or CPU bottlenecks when several builds are run at the same time.
After having one agent installed, you can install additional agent by following the regular installation procedure, but make sure that:
* The agents are installed in the separate directories.
* The agents have distinctive workDir and tempDir directories in buildAgent.properties file.
* Values for name and ownPort properties of buildAgent.properties are unique.
* No builds running on the agents have absolute checkout directory specified.
Moreover, make sure you don’t have build configurations with absolute checkout directory specified (alternatively, make sure such build configurations have “clean checkout” option enabled and they cannot be run in parallel).
Usually, for a new agent installation you can just copy the directory of existing agent to a new place with the exception of its “temp”, “work” and “logs” directories. Then, modify conf/buildAgent.properties with a new “name” and “ownPort” values.
If you are installing additional agents as services under Windows, modify the launcherconfwrapper.conf file so that wrapper.console.title, wrapper.ntservice.name, wrapper.ntservice.displayname and wrapper.ntservice.description properties have unique values within the computer. Then run binservice.install.bat script under user with sufficient privileges to register the new agent service.

Leave a Reply

Your email address will not be published. Required fields are marked *