Dynatrace tips
Tips and workarounds from Dynatrace users for Dynatrace users.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

HELP: How Can I Automatically Organize Applications into Segments Using Host Groups?

NicoleMT
Organizer

Good afternoon everyone,

I’m looking for some help with a Dynatrace configuration related to environment organization and application-based Segments.

Our goal is to organize our environment by application. We currently have around 4 applications, with multiple servers belonging to each application.

We were advised to follow this approach:

Step 1 – Set the Host Group on existing servers
The servers already have the appropriate Host Groups configured.

Step 2 – Configure Ingest Enrichment
The suggested approach is to create a rule under:

Settings → Collect and capture → Ingest enrichment configuration

For example:

  • Match: Host Group = APP-ACH-PROD

  • Map to: primary_tags.application

The idea is that this central mapping would allow current and future servers belonging to that Host Group to inherit the corresponding application tag automatically.

Step 3 – Build Segments using primary_tags.application
The Segments would then be based on the primary_tags values instead of configuring each server individually.

However, I’m having difficulty understanding exactly how Step 2 should be configured, especially the Ingest Enrichment rule and the correct mapping to primary_tags.application.

We have already been working with Support for several days, but we still haven't been able to get a clear example that works for our use case.

Our main objective is to segment the environment by application without having to manually configure every server or run commands individually. With Management Zones, this was much easier for us, so we are trying to achieve a similar centralized organization using the current Grail/Segments approach.

If anyone has already implemented Host Group → Ingest Enrichment → primary_tags.application → Segments, could you please share an example of how you configured the rule?

Even a screenshot or a simple example of the configuration would be extremely helpful.

Thank you very much in advance for any help! 🙏

1 REPLY 1

sujit_k_singh
Leader

Hi @NicoleMT 

I have completed the entire setup in my lab environment. Please see the details below:

As you have already created the Host Group, the first step is complete. In my test environment, I created a Host Group named Dev-Linux, and the host is successfully associated with it.

sujit_k_singh_0-1789699861767.png

The next step is Ingest Enrichment. Here, you can map the Host Group to a Primary Tag. In my configuration:

  • Source attribute: dt.host_group.id
  • Target: Primary Tag
  • Primary tag key: application
  • Condition: matchesValue(dt.host_group.id, "Dev-Linux")

This configuration automatically populates the Primary Tag with the Host Group value. The dt.host_group.id attribute resolves to the Host Group name and is mapped to primary_tags.application.

sujit_k_singh_1-1789699919176.png

Finally, I configured the Segment using the Primary Tag created by the Ingest Enrichment rule. After the configuration was completed, I was able to see the Dev Linux segment under the Infrastructure & Operations application, and the host associated with the Dev-Linux Host Group was displayed within that segment even other components too like process, containers, logs etc

sujit_k_singh_2-1789700029484.png

Now i can see segment under Infrastructure app

sujit_k_singh_3-1789700160906.png

sujit_k_singh_5-1789701030691.png

 

Thanks,

Sujit

 

Dynatrace Professional Certified

Featured Posts