02 Feb 2018 09:33 AM - last edited on 08 Dec 2021 02:43 PM by MaciejNeumann
Hi everyone,
Let me start by clarifying (if this was not clear from the title) that this is not a question, but rather sharing my experience in making an unmonitored host become part of the smartscape and even divided into services.
We have run into a situation in which a customer hosts his site on AWS and is initiating calls to his own internal SAP system to retrieve and update data. As he only installed dynatrace on AWS, the SAP servers were included in the unmonitored hosts.
So I've searched the forums and found this post. following you'll find the steps I've taken to achieve an end result in which I can see SAP transaction calls as follows:
As a preparation make sure you have the following:
Since I know I may need to run some additional calls to this server, I've defined in postman an environment and in that created my variables for the environment id and the token. (this has been demonstrated in one of the recent webinars, but as there are so many of them - definitely not a complaint - I couldn't find the right one to link here)
Now let's get to work.
The first thing we need to do is create a POST call to https://{{Env ID}}.live.dynatrace.com/api/v1/entity/infrastructure/custom/MYCUSTOMDEVICENAME. (everything within the double curly brackets is the postman variable which will be replace in the real value on runtime)
in order for this call to work you need the following request headers:
Then, we're off to the JSON content that described the host. There are a lot of values you can add to describe your host. To make this clear here are the minimum values I needed:
{
"displayName" : "name you want to appear on your smartscape and display",
"ipAddresses" : ["HOST IP"],
"listenPorts" : ["PORT1","PORT2"],
"type" : "CAN ACTUALLY BE ANYTHING",
}
Now go ahead and run your call. If everything goes well, your returned status should be 200 - ok.
Once the device is done, your next step is just to sit back and relax. from this point on Dynatrace automatically created a service for each port and allowed us to present it nicely, monitor, chart and even add our own request naming rules to make it appear as you've seen above.
Obviously you could take this even further and create custom services and even add some metrics and tags to the hosts, but one task at a time.
Hope this will help you all until we get the RFE implemented.
Solved! Go to Solution.
02 Feb 2018 03:15 PM
Hi Gil,
In my experience, this wouldn't last beyond 72 hours and will begin mapping back to "unmonitored hosts" after that timeframe. Please let me know if this works beyond that for you.
Thanks
NJ
03 Feb 2018 05:46 PM
Seems like you are right. after 72 hours, the host did in fact disapppear. I suspect this is because it did not receive any metrics and hence is automatically being cleared from the system.
Will check if custom service would do the trick instead of a host
03 Jul 2018 02:34 PM
Gil,
Did the custom service method work for you and maintain the metrics beyond 72hrs?
03 Jul 2018 04:30 PM
Matthew,
The custom service will not work as this requires an agent on the process to create a custom service. You may be able to create a custom service on the exact method on the monitored process that makes the request to the unmonitored tier but to have that unmonitored tier as a custom service is not possible.
Thanks
NJ
11 Jul 2018 08:37 PM
please upvote this RFE: Allow
easy way to create Service based on requests to unmonitored Hosts we hope it will be coming in Q3. The api timing out in 72 hours is a known issue per a ticket we had open DT but the fix for that is Q4 - so hopefully the easy way comes first 🙂
06 Sep 2018 07:16 PM
Hi Gil, so the only thing you did was get the info of the header of the call outside of the enviroment into a custom device? or did you did somthing else?
08 Sep 2018 09:18 AM
Hi @Alan P.
What do you mean header ? I used the host IP address (the one that is not monitored) and used it in the post command as described above.
Gil.
09 Sep 2018 07:43 AM
Hi! i ask, because in creating custom devices, but no "service" is getting attached to them. I only use the IP Address and the port of the "unmonitored host", but they keep getting added to the "unmonitored host" service in subsequent calls to them. You got any example of the post you did? Maybe im missing something silly...