---
title: Auto-discovery of AWS entities
source: https://docs.newrelic.com/docs/infrastructure/amazon-integrations/connect/set-up-auto-discovery-of-aws-entities
---

> #### 💡 PREVIEW
>
> We're still working on this feature, but we'd love for you to try it out!
>
> This feature is currently provided as part of a preview program pursuant to our [pre-release policies](https://docs.newrelic.com/docs/licenses/license-information/referenced-policies/new-relic-pre-release-policy).

**Auto-Discovery** is an [Advanced Compute](https://newrelic.com/pricing/compute#pricing_plan-compute) feature that automatically maps your AWS infrastructure, providing insights into the relationships between applications and their underlying resources. By enabling this feature, you gain a comprehensive view of your cloud environment, including current configurations and resource connections. Additionally, **Auto-Discovery** offers a reliability scorecard to assess your infrastructure against AWS best practices, aiding in effective management and optimization.

With **Auto-Discovery**, you can:

-   Automatically detect and visualize the relationships between AWS entities on [Maps](https://docs.newrelic.com/docs/service-architecture-intelligence/maps/advanced-maps).
-   Keep the representation of your infrastructure topology updated as changes occur in your AWS environment.
-   View the current configuration of your AWS resources.
-   Assess the reliability of your AWS infrastructure via the AWS reliability [Scorecards](https://docs.newrelic.com/docs/service-architecture-intelligence/scorecards/getting-started).

The **Auto-Discovery** feature is available only to **[Advanced Compute](https://newrelic.com/pricing/compute#pricing_plan-compute)** customers. To enroll, navigate to **[one.newrelic.com > Administration](https://one.newrelic.com/admin-portal) > Preview & Trials**, and enroll for **AWS Auto-Discovery**.

## Set up AWS integration with Auto-Discovery [#set-up-aws-integration-with-auto-discovery]

If you are setting up AWS integration for the first time and want to enable **Auto-Discovery**, follow these steps:

### Before you begin [#before-you-begin]

To set up AWS integration, ensure you have the following:

-   A New Relic [license key](https://one.newrelic.com/api-keys).
-   An AWS account with [permissions](https://docs.aws.amazon.com/ARG/latest/userguide/gettingstarted-prereqs-permissions.html) to deploy new AWS resources and [IAM roles](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html).
-   A New Relic account with [permissions](https://docs.newrelic.com/docs/accounts/accounts-billing/new-relic-one-user-management/user-permissions/#infrastructure) for cloud integrations.

### Select data type [#select-data-type]

1.  Log in to your [New Relic](https://one.newrelic.com/) account and navigate to **Infrastructure > AWS**.
2.  To integrate with AWS, select an account and click **Set up integration**.
3.  Select the data type as **Metrics**, **Logs**, or both, and continue.
4.  Select **Automate AWS with CloudFormation (Recommended)** and continue. This is currently the only setup method available for log integration.

### Select integration type [#select-integration-type]

**For Metrics data type**

If you have selected **Metrics** as data type, to set up integration, perform the following steps:

1.  Select metric integration type:
    -   **[Integration via CloudFormation and CloudWatch metric stream](https://docs.newrelic.com/docs/infrastructure/amazon-integrations/aws-integration-for-metrics/via-cloudformation-cwms/)** is the recommended method to create a real-time stream of metrics to New Relic.
    -   **[API Polling](https://docs.newrelic.com/docs/infrastructure/amazon-integrations/connect/set-up-aws-api-polling/)** is a legacy solution to receive AWS data in New Relic.

2.  Give a name to the selected integration.

3.  **CloudWatch Metric Streams** doesn't support few AWS services mentioned on the screen. If you want to include those services, select **Yes** and continue to configure API polling for those.

4.  Give a name for the API integration.

5.  Select the services you want to include in the integration, and continue.

**For Logs data type**

If you have selected **Logs** as data type, then there are multiple ways to send logs from your AWS services to New Relic. Select the path that best suits your needs. Both the integration instructions and the CloudFormation stack adapts to your selections.

1.  Select AWS sink(s):
    Most AWS service logs are generated in S3 buckets or CloudWatch log groups. Select one or both AWS sinks.
2.  Select log integration path(s):
    **Amazon Kinesis Data Firehose** is for direct and high-volume data streaming, and the **New Relic Lambda Function** is for high control over data transformation before forwarding logs.
3.  Set up trigger(s):
    Setting up triggers ensures that new logs are sent to New Relic every time an AWS service logs to an S3 bucket or a CloudWatch log group. With a single CloudFormation stack, you can configure up to 40 triggers (S3 buckets and/or CloudWatch log groups).
    -   For AWS service logs stored in S3 buckets, specify the **S3 bucket name** and **Prefix** (optional).
    -   For AWS service logs stored in CloudWatch log groups, specify the **Log Group** name and **Filter** (optional).
4.  Select New Relic logs API endpoint:
    The system automatically sets the endpoint based on the region of your New Relic account.
    -   For US account, logs are sent to `https://log-api.newrelic.com/log/v1`
    -   For EU account, logs are sent to `https://log-api.eu.newrelic.com/log/v1`
    -   For Japan account, logs are sent to `https://log-api.jp.nr-data.net/log/v1`
5.  Add custom attributes:
    Add custom attributes to organize your logs and make it easier to search, filter, analyze, and parse.

### Enable Auto-Discovery [#enable-auto-discovery]

Turn on the scan to enable Auto-Discovery of your AWS entities and continue. It enables the `cloudformation:StartResourceScan` permission in your AWS account to scan your AWS resources and discover the relationships between them.

> #### 💡 TIP
>
> By default, New Relic scans all regions enabled in your account once in a day. You can [update the scan frequency and regions](#select-region-and-frequency) after the stack is created, by managing the Auto-Discovery settings in New Relic.

### Connect to AWS [#connect-to-aws]

1.  Click **Launch your CloudFormation in AWS** to navigate to your AWS Console. The CloudFormation stack includes the configured parameters based on your selections in New Relic, so no additional editing is necessary unless you want to make changes.
2.  Copy and paste your license key into your AWS console.

We recommend you store your New Relic license key in **[AWS Secrets Manager](https://docs.aws.amazon.com/secretsmanager/latest/userguide/intro.html)** by keeping the environment variable set to `true` (default value).

### Deploy the CloudFormation stack [#deploy-cloudformation-stack]

After you customize the CloudFormation stack parameters to meet your requirements, click **Create stack**.
Creating the stack's resources may take several minutes and may generate multiple stacks, depending on how you configure log and metric forwarding. With a single deployment command, you can create a new stack to forward logs from multiple AWS resources.
If stack creation fails, refer to the [troubleshooting procedure](https://docs.newrelic.com/docs/logs/troubleshooting/aws-log-integration-issues/stack-creation-fails).

### Validate the AWS data on New Relic [#validate-aws-data]

After the new stack is created, go to **[New Relic](https://one.newrelic.com/) > Infrastructure > AWS** to view all integrated AWS services. If any New Relic service is connected to AWS entities, you can explore relationships from its map, including those between AWS entities, between APM entities, and between AWS and APM entities.

## Set up Auto-Discovery for an existing AWS integration [#set-up-auto-discovery-for-existing-aws-integration]

If you have already set up an AWS integration and want to enable **Auto-Discovery**, follow these steps:

### Before you begin [#prerequisite-for-existing-aws-integration]

To update AWS integration, ensure you have the following:

-   An AWS account with [permissions](https://docs.aws.amazon.com/ARG/latest/userguide/gettingstarted-prereqs-permissions.html) to deploy new AWS resources and [IAM roles](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html).
-   A New Relic account with [permissions](https://docs.newrelic.com/docs/accounts/accounts-billing/new-relic-one-user-management/user-permissions/#infrastructure) for cloud integrations.

### Manage AWS integrations [#manage-aws-integrations]

1.  Log in to your [New Relic](https://one.newrelic.com/) account and navigate to **Infrastructure > AWS**.
2.  To check whether Auto-Discovery is enabled for your AWS accounts, click **Manage AWS Integrations**.
3.  To enable Auto-Discovery for an AWS account, in the account list, click **Install** for that account.
4.  For Auto Discovery, click **Install**.

### Update the CloudFormation stack [#update-cloudformation-stack]

1.  To update the CloudFormation stack, on the side panel, click **Launch Cloudformation Template**.
2.  On the AWS console, acknowledge the CloudFormation stack and click **Create stack**.
3.  After the stack is created, go back to the New Relic.

### Select region and frequency of scan [#select-region-and-frequency]

By default, New Relic scans all regions enabled in your account once in a day. You can customize it as follows on the side panel:

-   To run the scan for specific regions, select or remove regions as per your requirement.
-   To change the frequency of the scan, select **Once a Day** or **Twice a Day**, as per your requirement.

### Enable Auto-Discovery [#enable-auto-discovery]

To enable Auto-Discovery, on the confirmation screen of New Relic, click **Save**.

**View configuration of an AWS entity**

After enabling Auto-Discovery, you can view the configuration of an AWS entity as follows:

1.  Go to **[New Relic](https://one.newrelic.com/) > All Capabilities** and select **Amazon Web Services**.
2.  To view the configuration of an AWS entity, select the entity from the list and click **Configuration explorer**.

**Disable Auto-Discovery**

> #### ⚠️ CAUTION
>
> When Auto-Discovery is disabled, you experience a loss of access to entities it identifies and their configurations. AWS Reliability Scorecards provide inaccurate scores, and the infrastructure map no longer displays relationships discovered by Auto-Discovery.

If you want to disable Auto-Discovery, follow these steps:

1.  Log in to your [New Relic](https://one.newrelic.com/) account and navigate to **Infrastructure > AWS**.
2.  To check whether Auto-Discovery is enabled for your AWS accounts, click **Manage Auto-Discovery**.
3.  From the account list, find the account in which you want to disable Auto-Discovery.
4.  To change the configuration, click **Edit**.
5.  On the side panel, turn off the scan.
6.  To disable Auto-Discovery, click **Save**.
