Splunk AppDynamics

Pulling metric data out

CommunityUser
Splunk Employee
Splunk Employee

Hello,

I have a application on top of an EC2 instance monitoring with appdynamics, can I pull the metrics  Memory used, CPU utilization, I/O and Heap from it and store in any external file?
If yes can you help me how can I do that.

Thank you in advance.

Labels (3)
0 Karma

Harish_Kumar
Explorer

Hello, 

You can use rest api to export the data. Please take a look on this doc for more details.

https://docs.appdynamics.com/display/PRO43/Metric+and+Snapshot+API#MetricandSnapshotAPI-RetrieveMetr...

OR 

Export from metric browser after adding the relevant metrics on it. Screenshot attached. 

Regards,

Harish

0 Karma

CommunityUser
Splunk Employee
Splunk Employee

Harish,

Thank you for the response. I follwed the document and I am struck in pulling the metrics out. I used the curl command as in the document, passed the credentials and the REST URL as in the attachment in the Document but, I am not able to get the metrics.

When I run

curl --user 'user1@customer1:secret' http://demo.appdynamics.com/controller/rest/applications/ECommerce_E2E/metrics

I can see the Output as in the attachment "Metric.PNG"

When I run

curl --user "user1@customer1:secret" http://demo.appdynamics.com/controller/rest/applications/ECommerce_E2E/metric-data?metric-path=Overall%20Application%20Performance%7CAverage%20Response%20Time%20%28ms%29\&time-range-type=BEFORE_NOW\&duration-in-mins=15

 I can see the error as in the attachment "REST URL.PNG". Can you please help me with this.

Thank you in advance.

0 Karma

Yogesh_Chouk
Builder

Hi,

In the attached screenshot "REST URL.PNG", we do not see the full API pasted in the command prompt. We only see below

duration-in-mins=15

Please try to copy full API and execute it again and let us know if you face any difficulty after this.

Thanks,

Yogesh

0 Karma

CommunityUser
Splunk Employee
Splunk Employee

Yogesh,

The attachment is the error I get after execution, and the command I ran is,

curl --user "user1@customer1:secret" http://demo.appdynamics.com/controller/rest/applications/ECommerce_E2E/metric-data?metric-path=Overall%20Application%20Performance%7CAverage%20Response%20Time%20%28ms%29\&time-range-type=BEFORE_NOW\&duration-in-mins=15

 Thank you.

0 Karma

Yogesh_Chouk
Builder

Hi,

Yes, as per the error in the screenshot it seems that you have missed specifying the type of the range.

Time range type is not specified

Could you please verify the Rest API if you have specified the time range type.

time-range-type=BEFORE_NOW

Please share full screenshot of the request and response both if you still face issue after verifying above.

 

Thanks,

Yogesh

0 Karma

Esko_Jaakkola
Explorer

Hello,

I'll get same error:

curl --cacert xxxxx --user "xxxxx" https://145.247.129.49:8181/controller/rest/applications/LTS_TUO_Tuonti/metric-data?metric-path=Busi...
[1] 4024
[2] 4025
<html><body><h1>500 Internal Server Error</h1><br/>Exception Id:97d08166-e4cb-470a-a1b8-3e6654ffa1b9<br/></body></html>

time-range-type=BEFORE_NOW: command not found
duration-in-mins=60: command not found

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Agent Mode Engaged! Enchaining Agentic Operations with Splunk AI Assistant 2.0

    Are you ready to transform how your team handles complex data requests? We invite you to our upcoming ...

Announcing Modern Navigation: A New Era of Splunk User Experience

We are excited to introduce the Modern Navigation feature in the Splunk Platform, available to both cloud and ...

Modernize your Splunk Apps – Introducing Python 3.13 in Splunk

We are excited to announce that the upcoming releases of Splunk Enterprise 10.2.x and Splunk Cloud Platform ...