I would like to install another agent on a machine that currently has an agent installed

I would like to install a second agent on a machine and was wondering if it was possible to do so without running a vmware virtual machine. If it, I would appreciate if you could point me to some directions on how to do so.

Thanks,

Brian

2 answers

For our setup, we currently run some really big build boxes (24 cores, 24gb of ram, etc)

We actually have 3 agents setup on these boxes since they can handle more than 1 compilation at a time. The key is to give the agents different "homes" to work in, then you can ideally run as many as you want. The way we do it depends differently on if it's windows or linux.

If it's linux (we use centos, but this should be the same for most) we launch our agents from the rc.local file during startup. We have 3 entries in that file for all 3 agents we run. We start our agents this way:

java -Dbamboo.home=/bamboo-agent-home-1/ -jar /bamboo-agent-home-1/atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer &

java -Dbamboo.home=/bamboo-agent-home-2/ -jar /bamboo-agent-home-2/atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer &

java -Dbamboo.home=/bamboo-agent-home-3/ -jar /bamboo-agent-home-3/atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer &

If it's windows, we did things a bit differently. We created a "bat" script that's executed at the system startup that launches all 3 agents. The contents look like this:

rem ## START THE FIRST AGENT ##
start java -Dbamboo.home=C:\\bamboo-agent-home-1\\ -jar C:\\bamboo-agent-home-1\\atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer/

rem
## START THE SECOND AGENT ##
start java -Dbamboo.home=C:\\bamboo-agent-home-2\\ -jar C:\\bamboo-agent-home-2\\atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer/

rem
## START THE THIRD AGENT ##
start java -Dbamboo.home=C:\\bamboo-agent-home-3\\ -jar C:\\bamboo-agent-home-3\\atlassian-bamboo-agent-installer-3.3.2.jar http://host:port/agentServer/

I have no idea what OS you are using or your experience with them but I will go ahead and explain that in the linux version we add the "&" symbol to the end of the line in order to background the task. This prevents the OS halting the script on that line during execution. We just tell it to start and move on with the rest of the commands. In windows, prefixing the command with "start" does the same thing.

Our windows script will also kill the other agents if they happen to be running.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,561 views 0 6
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you