Agent-Collector Mapping in loadbalanxing.xml Does Not Work as Expected

Document ID : KB000099243
Last Modified Date : 12/06/2018
Show Technical Document Details
Issue:
There are altogether 6 collectors in this CA APM Cluster.
We intend to assign 3 different groups of agents to 3 designated Collectors (1.1.1.1, 2.2.2.2, 3.3.3.3) respectively.

For instance, the desired result is to only have "XIC" prefixed agents connecting to Collector at 1.1.1.1:5001, "pa" prefixed agents connecting to Collector at 2.2.2.2:5001 and "nonpa" prefixed agents connecting to Collector at 3.3.3.3:5001. All other remaining agents can be pointed to any of the remaining 3 collectors.

Below is what we've configured in the loadbalancing.xml in an attempt to achieve the mentioned outcome:

#For all agents prefixed XIC
<agent-collector name="XIC Agents">
<agent-specifier>XIC.*\|.*\|.*</agent-specifier>
<include>
<collector host="1.1.1.1" port="5001"/>
</include>
</agent-collector>

# For all agents prefixed pa
<agent-collector name="Prod Agents">
<agent-specifier>pa.*\|.*\|.*</agent-specifier>
<include>
<collector host="2.2.2.2" port="5001"/>
</include>
</agent-collector>

#For all agents prefixed nonpa
<agent-collector name="Non Prod Agents">
<agent-specifier>nonpa.*\|.*\|.*</agent-specifier>
<include>
<collector host="3.3.3.3" port="5001"/>
</include>
</agent-collector>

However, with above configuration, all agents are connecting to any of the 6 collectors.
 
Environment:
CA Application Performance Management 10.5.2 Cluster consisting of 1 MOM and 6 Collectors


 
Cause:
The configuration is incomplete, you will need to define in the load balancing xml, on how the rest of the un-mapped agents are to be handled, and excluded from connecting to the specific collectors.
Resolution:
To address this load balancing need, you will need to use the catch-all phase at the end of the load balancing configuration, to catch all other un-mapped agents. You can also specify within the catch-all phase to exclude the specific collectors from being mapped/connected to these agents, by using the <exclude> clause.

For example:

#For all agents prefixed XIC
<agent-collector name="XIC Agents">
<agent-specifier>XIC.*\|.*\|.*</agent-specifier>
<include>
<collector host="1.1.1.1" port="5001"/>
</include>
</agent-collector>

# For all agents prefixed pa
<agent-collector name="Prod Agents">
<agent-specifier>pa.*\|.*\|.*</agent-specifier>
<include>
<collector host="2.2.2.2" port="5001"/>
</include>
</agent-collector>

#For all agents prefixed nonpa
<agent-collector name="Non Prod Agents">
<agent-specifier>nonpa.*\|.*\|.*</agent-specifier>
<include>
<collector host="3.3.3.3" port="5001"/>
</include>
</agent-collector>

<agent-collector name="CatchAll Exclude">
<agent-specifier>.*\|.*\|.*</agent-specifier>
<exclude>
<collector host="1.1.1.1" port="5001"/>
<collector host="2.2.2.2" port="5001"/>
<collector host="3.3.3.3" port="5001"/>
</exclude>
</agent-collector>
Additional Information:
Configure MOM Agent Load Balancing
Loadbalance.xml: Catch-all phase is usually recommended to be placed at the bottom of the list.