Updated on 2024-08-05 GMT+08:00

Obtaining the Service Address of a Prometheus Instance

In the Service Addresses area on the Settings tab page of the default Prometheus instance or of the Prometheus instance for CCE, and remote write, you can obtain the configuration code for Prometheus remote read and write. In the Service Addresses area on the Settings tab page of the Prometheus instance for cloud services, you can obtain the configuration code for Prometheus remote read.

Prerequisites

Your service has been connected for Prometheus monitoring. For more details, see:

Procedure

  1. Log in to the AOM 2.0 console.
  2. In the navigation pane on the left, choose Metric Analysis > Prometheus Monitoring. In the instance list, click the created Prometheus instance.
  3. On the instance details page, choose Settings in the navigation pane to obtain the service address of the current instance.

    The following describes how to obtain the service address of a Prometheus instance for CCE.

    • Click the Intranet tab to obtain the configuration code for Prometheus remote read and write in the intranet. Click on the right of the code to copy the code to the corresponding file.
    • Obtain the configuration code for Prometheus remote read.
      Figure 1 Configuration code for Prometheus remote read

      Remote read address:

      url: 'https://aom.{region_name}.{Site domain name suffix}/v1/{project_id}/api/v1/read'
      Remote read address parameters:
      • region_name: domain name or IP address of the server where the REST service is deployed. The value varies depending on services and regions.
      • Site domain name suffix: site domain name suffix.
      • project_id: project ID.
    • Obtain the configuration code for Prometheus remote write.
      Figure 2 Configuration code for Prometheus remote write

      Remote write address in the intranet:

      url: 'https://aom-internal-access.{region_name}.{Site domain name suffix}:8443/v1/{project_id}/push'

      Remote write address in the public network:

      url: 'https://aom-access.{region_name}.{Site domain name suffix}:8443/v1/{project_id}/push'
      Remote write address parameters:
      • region_name: domain name or IP address of the server where the REST service is deployed. The value varies depending on services and regions.
      • Site domain name suffix: site domain name suffix.
      • project_id: project ID.