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

A simple DQL to do a search for an IP to host in Dynatrace.

MarwanC
Guide

I appreciate a simple DQL to search for a host name given an IP. How simple could it be?

2 REPLIES 2

Mizső
DynaMight Guru
DynaMight Guru

Hi @MarwanC,

I hope I understand your request well. To be honest I am not a DQL guru I have just started to learn.

I would create a dashboard with this DQL (you can add other extra fields if you want).

fetch dt.entity.host
| fieldsAdd ipAddress, entity.detected_name
| filter in (ipAddress, array($IP) )

In order to work well I created a variable = IP

Variable DQL:

fetch dt.entity.host
| fieldsAdd ipAddress
| fieldsRemove entity.name, id

Mizs_3-1700074964582.png

 

This is the results, you can search hosts by IP address:

Mizs_0-1700074310580.png

Mizs_1-1700074445585.png

I hope it helps.

Best regards,

Mizső

Dynatrace Community RockStar 2024, Certified Dynatrace Professional

A very comprehensive answer 😊

Have a nice day!

Featured Posts