cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Filtering Logs -Best Practice

shakib
Participant

I was wondering if anyone wanted to share how they're filtering logs in a way aside from Management Zones if they want to review data for a particular group of hosts/applications. 

 

Currently I have Management Zones set-up where QA servers are in their own MZ's and so if I want to see dashboards/logs/etc. for QA only I can just go to the QA MZ. 

 

With logs, I was hoping that I could filter logs via host.group or host.tag because that would have made it tremendously helpful to be able to limit my search criteria based on host groups or host tags because otherwise I see limited value in host groups or host tags. But at the moment my thoughts are that I have to limit the data based on Management Zones if I only want to filter based on QA.

I do realize I can search for only QA servers (where I enter one server at a time due to the wildcard not being allowed in the middle of a search criteria (like a host name)), but that is not going to be as useful if I want to search for something among plethora of servers. 

 

Maybe re-purposing dt.process_groups? 

I do realize that Dynatrace is not meant to be a log viewing tool but if someone still wanted to view logs, the current set-up leaves an entire universe to be desired. 

1 REPLY 1

Fin_Ubels
Dynatrace Advisor
Dynatrace Advisor

Hey shakib,

The best way I have seen log filtering done is with manual log ingestion rather than the automated system. With the manual method through the API you can attach custom key value pairs to then use for filtering in the UI. While this doesn't help with your current predicament it could be something to look into implementing if you have the time.

Fin_Ubels_0-1651187033262.png

An example of what this looks like.



Below are a couple of documentation pages for reference.
https://www.dynatrace.com/support/help/how-to-use-dynatrace/log-monitoring/acquire-log-data/log-data...

https://www.dynatrace.com/support/help/dynatrace-api/environment-api/log-monitoring-v2/post-ingest-l...