Overview

This page describes how Cloud Monitoring presents its services to you and how you can configure Cloud Monitoring for your Google Cloud project. This page is intended for developers and system administrators.

Before you begin

If you created your Cloud project, then you have sufficient permissions to use Cloud Monitoring. If you've been granted access to a project, ensure that your role has sufficient permissions to use Cloud Monitoring. For information about the required roles, see Authorization.

Understanding the data-model change

Monitoring is changing the way data related to your projects is organized. When the replacement is complete, you'll be able to share a project's metrics with other projects, providing you with multiple ways to view your data.

The transition to the new data model is to occur gradually and has multiple phases. In the initial phase, your projects are to be converted to a hybrid model. This transition impacts how you navigate to a Workspace. In the final phase, all of your projects will be migrated to the new data model.

During the transition, you can continue to use Cloud Monitoring.

The remainder of this section describes how to identify the data model used by your project, and it provides information on the navigation change.

Identifying your project's data model

To identify the Monitoring data model for a project, do the following:

  1. Select your project using the Cloud Console project picker.
  2. In the navigation pane, click Monitoring.
  3. Ensure that the Monitoring navigation pane is expanded. If it isn't, click Last page .

    • If the navigation pane only includes a Workspace picker and a list of services, then your project is using a Workspace. Some of the content on this page is relevant to your configuration. For information about creating a Workspace, see Creating a Workspace.

      Cloud Monitoring navigation with Workspace data model.

    • If your project includes a metrics scopes field and a list of services, then your project has been migrated to the new data model. Most of the content on this page is relevant to your configuration.

      Cloud Monitoring navigation pane for metrics scope data mode.

    • If your project includes a Workspace picker and a field labeled View related Workspaces, then your project is using a hybrid data model. Most of the content on this page is relevant to your configuration.

      Cloud Monitoring navigation pane during migration.

      The next section describes how Cloud Monitoring navigation is changed for projects with this data model.

This section applies to projects that use the hybrid data model.

The change in navigation is due to a new feature supported by the hybrid data model; this model lets every Cloud project be both a host project for a Workspace and a monitored project.

If a Workspace is monitoring a single project, then navigation to that Workspace isn't affected by the data-model change. To access the Workspace, select the project with the Cloud Console project picker and then go to the Monitoring page.

If a Workspace is monitoring multiple projects, then the migration affects how you access that Workspace. To access a multi-project Workspace, do one of the following:

  • Select the Workspace's host project with the Cloud Console project picker and then go to the Monitoring page.
  • Select a monitored project with the Cloud Console project picker and go to the Monitoring page. To change to the multi-project Workspace, do one of the following:

    • Use the Workspace picker to select the multi-project Workspace.
    • Expand View related Workspaces, select a project from the table labeled The projects listed below can view this project's metrics. If this table is empty, the current project's metrics aren't visible to any other Workspace.

Configuring your project for Cloud Monitoring

This section applies all data models.

Configuration isn't required for projects using the hybrid or metrics scope data models.

If a project is using the Workspace data model, then the first access of Cloud Monitoring for a Cloud project by a user with a role that includes Monitoring Editor initiates all required configuration activities for that project.

Understanding metrics scopes

This section only applies to the metrics scope data model.

Cloud Monitoring lets you view and manage the metrics for projects in the following ways:

  • For a single project
  • For multiple projects
  • For multiple Google Cloud projects and AWS accounts

You determine which metrics you want to view by configuring a metrics scope. The metrics scope lists all of the projects and accounts it monitors, and it is hosted by a scoping project. The scoping project is the Cloud project that is selected in the Cloud Console project picker, and it stores the alerts, uptime checks, dashboards, and monitoring groups that you configure for the metrics scope.

With this data model you can view a project's metrics in isolation as well as in combination with metrics stored by other projects. For example, assume that you have two projects, Project-A and Project-B, that contain Compute Engine virtual machine (VM) instances. Assume that you have another project, Project-Multiview, that you've configured so that it can view the metrics for Project-A and Project-B. Now, there are two different ways you can view the metrics of Project-A:

  • If you select Project-Multiview with the Cloud Console project picker and then go to the Monitoring page, you view the metrics scope for Project-Multiview and you can see the metrics for all three projects:

    Figure illustrating the multi-view metrics scope.

  • If you select Project-A with the Cloud Console project picker and then go to the Monitoring page, you view the metrics scope for Project-A and you can only see the metrics for that project:

    Figure illustrating the metrics scope of `Project-A`.

For information on configuring a metrics scope to include metrics for multiple projects, see Viewing metrics for multiple projects.

Determining the visibility of metrics

This section applies to projects that use the hybrid and metrics scope data models.

To determine the visibility of metrics for your project, do the following:

  1. Select your project using the Cloud Console project picker.
  2. In the navigation pane, click Monitoring.
  3. Ensure that the Monitoring navigation pane is expanded. If it isn't, click Last page.
  4. Click Expand on the Metrics scope or View related Workspaces field.

    For both data models, the displayed data is similar. The following screenshot illustrates the page displayed for the metrics scope model when Project-Multiview is selected in the Cloud Console project picker:

    Sample of the page that lists the monitored projects.

    The table labeled Metrics monitored by this project lists the projects whose metrics can be viewed with the current metrics scope. Each row in the table lists a project and that project's role:

    • Scoping project indicates that the project stores the uptime checks, alerting policies, groups, and dashboards that you configure. A metrics scope contains a single scoping project. A project can be a scoping project for a single metrics scope. For this example, Project-Multiview is the scoping project.

    • Monitored project indicates that the metrics for the Google Cloud project or AWS account are visible to the current metrics scope. For this example, Project-A and Project-B are monitored projects.

    To identify any other projects that can access the metrics of this project, look for the projects listed under the header The projects listed below can view this project's metrics. In the previous screenshot, no other projects can access the metrics stored by Project-Multiview.

Modifying your project's Cloud Monitoring configuration

This section applies all data models.

You can modify your project's Cloud Monitoring configuration so that you can view and monitor metrics for multiple Google Cloud projects or AWS accounts. The projects or accounts that you add to the current metrics scope, or to the current Workspace, are called monitored projects.

Adding a monitored project

To add a monitored project, do the following:

  1. In the Monitoring navigation pane, select Settings.
  2. To add a Google Cloud project, click Add GCP Projects and complete the dialog. Before you add a monitored project, we recommend that you read Viewing metrics for multiple projects.

  3. To add an AWS account as a monitored project, do one of the following:

    • Click Add AWS Account if this button is displayed. This step creates an AWS connector project and then adds the AWS connector project as a monitored project to your current Workspace. This button is displayed for the hybrid and Workspace data models.
    • Click Create AWS connector project to connect an AWS account to Google Cloud—this step creates an AWS connector project—and then adds the AWS connector project as a monitored project to your current metrics scope.
    • Click Add AWS connector projects to add an existing AWS connector project as a monitored project to your current metrics scope.

    Before you add an account, we recommend that you read Viewing metrics for an AWS account.

Removing a monitored project

To remove a monitored project, do the following:

  1. In the Monitoring navigation pane, select Settings.
  2. To remove one or more Google Cloud projects, in the GCP Projects in scope pane, select the projects that you want to remove and click Remove project.
  3. To remove one or more AWS accounts, in the AWS Accounts in scope pane, select the AWS connector projects that you want to remove and click Remove project.

  4. Delete any AWS connector projects that you removed and that are no longer monitored projects.

Changing the current metrics scope

This section only applies to the metrics scope data model.

The project selected in the Cloud Console project picker is the scoping project of the current metrics scope. A project can be the scoping project for one metrics scope.

To select a different metrics scope, do one of the following:

  • Select a different project in the Cloud Console project picker. The Cloud Console project picker lists all projects that you can access.

  • In the navigation pane, click Expand in the metrics scope field, and then select a project from one of the tables. One table on this page lists the projects whose metrics are visible to the current project. The other table lists the projects that can view the current project's metrics.

Disabling Monitoring

This section applies all data models.

To disable the collection of Monitoring data in a Google Cloud project or in an AWS connector project, do the following:

  1. From the Cloud Console, select the Cloud project or the AWS connector project, and then go to the APIs & Services page:

    Go to APIs & Services

  2. Select Cloud Monitoring API.

  3. Click Disable API

Viewing your bill

This section applies all data models.

To view your bill for a project, do the following:

  1. In the Monitoring navigation pane, select Settings.
  2. In the Settings page, select Overview.
  3. Locate the project, click More options and then select View bill.

For each project, the column Month to date displays the byte count of billable metrics for the current calendar month. Similarly, the Previous month column lists the total ingested byte count for the previous calendar month. Lastly, the Monthly projection column provides an estimate of the total byte count of billable metrics for the current calendar month:

Authorization

This section applies all data models.

This section describes the roles or permissions needed to view, create, or modify a metrics scope or a Workspace. For detailed information about Identity and Access Management(IAM) for Monitoring, see Access control.

To view the metrics scope or the Workspace for a Cloud project, you must have one of the following IAM roles for the project:

  • Monitoring Viewer
  • Monitoring Editor
  • Monitoring Admin
  • Project Owner

To create a metrics scope or Workspace for a Cloud project, you must have one of the following IAM roles for the project:

  • Monitoring Editor
  • Monitoring Admin
  • Project Owner

To modify a metrics scope or Workspace, you must have one of the following IAM roles for the scoping project of the metrics scope and for the project to be added (or removed) as a monitored project:

  • Monitoring Editor
  • Monitoring Admin
  • Project Owner

To view a list of roles and their associated permissions, see Roles.

What's next