Icon

Comments have been closed on this page. Please use AppMon & UEM Plugins forum for questions about this plugin.

Overview

The Dynatrace AppMon FastPack for Amazon EC2 Account Cost Monitoring monitors EC2 instances and CloudFormations of an Amazon AWS Account. It provides a monitor which retrieves measures for the number of instances/formations as well as cost estimations. The FastPack consists of a custom Monitor, a sample System Profile, and a dashboard.

FastPack Details

Name

Amazon EC2 Account Cost Monitoring FastPack

Version

5.5.0.5227

dynaTrace Version

dynaTrace 5.5 and higher

Author

dynaTrace software

License

dynaTrace BSD

Support

Not Supported

FastPack Contents

Amazon EC2 Account Cost Monitoring FastPack

Description

This FastPack extends performance data collection to number of instances on Amazon EC2 and estimated cost. It

  • Captures number of instances and calculates resulting cost
  • Provides ready made System Profile and Dashboard for visualization of results
  • Allows alerting on number of instances or running/daily/monthly costs
  • Configurable region handling and cost estimations

To achieve this, this plugin uses the Amazon Webservices interfaces to periodically retrieve information about the number and types of EC2 instances and CloudFormations that are running in a configured Amazon AWS account and calculates related measures.

Installation

  • Download the plugin file
  • On Windows, double click the file to install it in the Dynatrace Client, on Unix systems you can use "Tools - Manage Plugins - Install Plugin" in the Dynatrace Client
  • This will automatically add a System Profile "AmazonAccount" which contains a Montior configuration
  • Configure the Monitor properties via "AmazonAccount - Edit System Profile - Monitors" and right choose "Edit" on the "Amazon Account" entry (not "Amazon Account Monitor"!)
  • Enter values for at least accessKeyID and secretKeyID, you get these values in the Amazon AWS console under "Account".
  • Optionally you can choose to monitor only certain regions, default is to include all Amazon regions
  • Instance Costs should be pre-populated, you can adjust them if Amazon changes these costs.
  • The setting "Persist accross restarts" allows to make the calculation more accurate in cases where dynaTrace is restarted or is offline for some time. This requires a temporary folder (on the machine where the related dynaTrace Collector executes) and a unique id to work properly.
  • The setting "Use proxy for connecting Amazon AWS" allows to define proxy settings when the dynaTrace Collector is running inside a corporate network with limited Internet access.

Amazon EC2 Account Cost Dashboard

Measures

Amazon Cloud FormationsProvides metrics about used cloud formation stacks.
FormationActiveCountNumber of cloud formation stacks that are active, i.e. CREATE_COMPLETE or any of the ..._IN_PROGRESS states.
Count_CREATE_IN_PROGRESSNumber of cloud formation stacks that are currently created.
Count_CREATE_FAILEDNumber of cloud formation stacks where creation failed.
Count_CREATE_COMPLETENumber of cloud formation stacks that are fully created.
Count_ROLLBACK_IN_PROGRESSNumber of cloud formation stacks where rollback is underway.
Count_ROLLBACK_FAILEDNumber of cloud formation stacks where rollback failed.
Count_ROLLBACK_COMPLETENumber of cloud formation stacks where rollback is done.
Count_DELETE_IN_PROGRESSNumber of cloud formation stacks where deleting is underway.
Count_DELETE_FAILEDNumber of cloud formation stacks where deleting failed.
Amazon EC2 InstancesProvides metrics about used Amazon EC2 instances.
EC2ActiveCountNumber of EC2 Instances that are not terminated and not stopped.
EC2CountStoppedNumber of EC2 Instances that are stopped.
EC2CountPendingNumber of EC2 Instances that are currently started.
EC2CountRunningNumber of EC2 Instances that are running.
EC2CountShutting-downNumber of EC2 Instances that are currently shutting down.
EC2CountTerminatedNumber of EC2 Instances that are terminated.
Amazon EC2 Instance CostsProvides metrics for approximate costs of the currently active Amazon EC2 instances.
CostOverallCost since last invocation for currently resvered instances which are not terminated or stopped. Note that these are estimated costs as instances that are started and stopped within one hour still cause cost. Also the costs do not include additional costs for storage and transfers.
CostM1SmallCost since last invocation for instances of type m1.small.
CostM1MediumCost since last invocation for instances of type m1.medium.
CostM1LargeCost since last invocation for instances of type m1.large.
CostM1XLargeCost since last invocation for instances of type m1.xlarge.
CostM3XLargeCost since last invocation for instances of type m3.xlarge.
CostM32XLargeCost since last invocation for instances of type m3.2xlarge.
CostT1MicroCost since last invocation for instances of type t1.micro.
CostM2XLargeCost since last invocation for instances of type m2.xlarge.
CostM22XLargeCost since last invocation for instances of type m2.2xlarge.
CostM24XLargeCost since last invocation for instances of type m2.4xlarge.
CostC1MediumCost since last invocation for instances of type c1.medium.
CostC1XLargeCost since last invocation for instances of type c1.xlarge.
CostCC14XLargeCost since last invocation for instances of type cc1.4xlarge.
CostCC28XLargeCost since last invocation for instances of type cc2.8xlarge.
CostCG14XLargeCost since last invocation for instances of type cg1.4xlarge.
CostHI14XLargeCost since last invocation for instances of type hi1.4xlarge.

New features in Version 5.5.0

  • Update Cost Values, add new Amazon AWS data center locations
  • Try to automatically retrieve current costs from Amazon web page, fall back to configured costs if not found or network is not available
  • Add some measures for costs for RDS database instances: RDSActiveCount, RDSCountByClass, RDSCostOverall, RDSCostByClass
  • Provide new dynamic measures to avoid having to update the plugin when amazon introduces new instance types in the future
    • CostOverall by Usage, i.e. custom tag "Usage" on the EC2 Instance
    • CostOverall by Type, i.e. instance type
    • CostOverall by Owner, i.e. custom tag "Owner" on the EC2 Instance
    • EC2ActiveCount by Usage
    • EC2ActiveCount by Owner
    • RDSCostOverall by Status
    • RDSCostByClass by Instance Class
    • RDSActiveCount by Status
    • RDSActiveCountByClass by Instance Class
  • Update to Amazon SDK 1.7.3

Known Problems/Limitations

  • As Amazon does not make the actual running costs available, the cost calculation is only an estimate, the actual values billed by Amazon might vary slightly.
  • The plugin only calculates cost for the EC2 instances, costs for storage, network traffic and other Amazon Services are not taken into account.

Contribution

Feel free to contribute any changes on Github

  1. Anonymous (login to see details)

    Hey Dominik, has this been tested for 5.x and more specifically 5.5?

  2. Anonymous (login to see details)

    It should basically still work, only Amazon has added a number of new instance types and adjusted prices quite a bit, so you will need to update the price-information in the properties.

    I'll try to upload a newer version which provides these prices out of the box and even tries to keep them up-to-date automatically as far as possible (Amazon is somewhat reluctant to officially publish machine-readable price information...).

  3. Anonymous (login to see details)

    Awesome, thanks for the quick response Dominik! This is a great plugin and I think my customer will get quite a bit of use out of it.  Nice job!

    1. Anonymous (login to see details)

      Obviously I didn't manage to update it until now and it will take a bit longer still as I am out of the office now for 2 weeks, stay tuned by watching the page!

      1. Anonymous (login to see details)

        Please give the new version a try, should work with dynaTrace 5.5 up to 6.0, some new features added as well!

  4. Anonymous (login to see details)

    Hi Dominik,

    Do we have a specific customer use case for this? Who are the folks that typically want to see this data? Just curious, a very interesting plug-in.

    1. Anonymous (login to see details)

      It's an easy way to see how many instances are used or get created on an Amazon AWS account together with a rough estimation of costs.

      Typical users are people monitoring usage/costs as well as e.g. a Hall-Monitor displaying current usage for everybody to see.

      It let's you integrate this data into dynaTrace so you don't need to look somewhere else for these metrics, but rather you can then use all of dynaTrace on them, e.g. charting or alerting when too many instances are used, .... together with historical data about usage in the past.

      Target audience is likely a light to intermediate user of Amazon AWS services as anybody using more services and/or lots of instances will want to handle creation/usage in a more controlled manner via a specialized tool-set.

  5. Anonymous (login to see details)

    Hi - what are the minimum account rights to get this working? We're currently seeing an access denied message.

    1. Anonymous (login to see details)

      The monitor uses the following classes from the API, so it should work with fairly basic read-only access to EC2, StackFormation and RDS

      • DescribeStacksRequest
      • DescribeInstancesRequest
      • DescribeRegionsRequest
      • DescribeDBInstancesResult