If you authorize New Relic to fetch data through a user account, New Relic accesses your GCP project monitoring data on behalf of a particular Google user.
New Relic uses an OAuth workflow for authorization, which redirects you from the New Relic UI to a Google authorization interface. However, because the authorization is linked to a particular Google user, we don't recommend this method for GCP projects that large teams manage.
Conseil
This authorization method doesn't let New Relic collect tags and other attributes that can be useful for narrowing down your NRQL queries, dashboards, and alerts. You can migrate the authorization method from user account to service account from the Manage services link in New Relic user interface.
Requirements
These are the requirements for the authorization:
Requirement | Details |
|---|---|
Monitoring | In the GCP project API & Services Library settings, you must enable Google Stackdriver Monitoring API. |
Authorization | The New Relic user who integrates the GCP project must have a Google account and be able to view the GCP project that New Relic monitors. In the GCP project IAM & admin, the user must have the Project Viewer and Monitoring viewer roles. |
Project name | As part of the online setup process, you must identify the |
Permissions | New Relic doesn't inherit your Google account's permissions and therefore can't make any changes in the project. New Relic also requires a specific set of read-only permissions exclusively for certain types of data. For more information about the API permissions that New Relic uses, see the Google documentation about scopes. |
Connect GCP to New Relic infrastructure monitoring
Important
If this is your first time setting up GCP with New Relic, ensure that you've enabled Cloud Monitoring API for your project. You can do this in the Google Cloud console.
To connect your Google account to New Relic with user account authorization:
Go to one.newrelic.com > All capabilities > Infrastructure > GCP. On the Google Cloud Services integrations page, select Add a GCP account.
Choose Authorization Method: Select Authorize a User Account, and follow the instructions in the UI to authorize New Relic.
Add projects: Select the projects that you want New Relic to receive data from.
Select services: From the list of available services for your GCP account, select the individual services you want New Relic to receive data from, or select all of the services.
Important
New Relic enables these services for all of the projects you selected in the previous step. After setup finishes, you can fine-tune the services you want monitored for each project individually.
To complete the setup process, select Finish.
If you see API authentication errors, follow the troubleshooting procedures.
New resources may take a few minutes to be detected and synthesized as entities. For more information, see Cloud integrations system limits.
View your GCP data
After you connect, New Relic starts monitoring your GCP data at regular polling intervals, and your data appears in the New Relic UI after a few minutes. To learn how to view, query, and explore it — including dashboards, alerts, and entities — see View and query your GCP data.
Link multiple Google projects
The setup process lets you select more than one project at a time.
After the first setup, to monitor additional GCP projects with New Relic, repeat the procedure to connect your GCP services as many times as you need.
Disable or unlink your GCP integrations
You can disable any of your GCP integrations any time and still keep your Google project connected to New Relic.
Disable one or more GCP services
To disable services while keeping your GCP account linked to New Relic:
- Go to one.newrelic.com > All capabilities > Infrastructure > GCP > Manage services.
- From your Edit GCP account page, clear the checkbox for each active service you want to disable.
- Save your changes.
Disconnect and unlink your account
To completely disconnect from New Relic, unlink your GCP account. This disables all New Relic integrations associated with it.
- Go to one.newrelic.com > All capabilities > Infrastructure > GCP > Manage services.
- From your Edit GCP account page, select Unlink this account.
- Save your changes.
Clean up GCP after unlinking
To clean your GCP project after unlinking:
- Open your Google user account settings.
- Open the Apps with access to your account section.
- Select the New Relic application.
- Select Remove Access.