Some customers have complete enterprise IT management systems in their data centers and expect to export data from the cloud to data centers in real time for centralized monitoring. This topic describes two methods that you can use to export monitoring data to a self-managed Prometheus instance.
Background information
You are not charged for activating Hybrid Cloud Monitoring. You are charged based on the actual resource usage. For information about the billing of the cloud monitoring exporter feature, see Billing of the cloud monitoring exporter feature.
Prerequisites
Solution | Prerequisites | |
Method 1 | Hybrid Cloud Monitoring is activated. For more information, see Activate Hybrid Cloud Monitoring. | Managed Service for Prometheus is activated. Go to the buy page of Managed Service for Prometheus and activate the service as prompted. |
Method 2 | The self-managed Prometheus instance is connected to Cloud Monitor. Note You can use the Internet or a virtual private cloud (VPC). You can also specify a proxy. | |
Procedure
Method 1: Use Managed Service for Prometheus to deliver data (recommended)
Integrate the monitoring data of Cloud Monitor into a Managed Service for Prometheus instance. For more information, see Monitor an Alibaba Cloud service.
Deliver data from the Managed Service for Prometheus instance to your self-managed Prometheus instance. For more information, see Deliver data from a Managed Service for Prometheus instance to a self-managed one.
Benefits:
Managed Service for Prometheus is a fully managed service. You do not need to maintain an exporter.
Data is delivered in real time with lower data latency.
Managed Service for Prometheus can provide more context by enriching tags for Cloud Monitor metrics.
Method 2: Use the Cloud Monitor exporter to export data
Cloud Monitor provides a real-time monitoring data exporter. The exporter can run in your data centers to obtain monitoring data from Cloud Monitor in real time based on configurations and continuously write the data to self-managed Prometheus instances.
Download, install, and configure open source Prometheus. For more information, see First steps with Prometheus.
NoteFor more information about Prometheus, see Overview.
Download the real-time monitoring data exporter.
NoteCloud Monitor updates the exporter regularly. If you require new features, download and reconfigure the exporter of the new version.
Configure the exporter.
Decompress the installation package to obtain the following files: configs, exporter_local, and ReadMe.pdf. For more information about how to configure the real-time monitoring data exporter, see "Description of each item in the configuration file" in the ReadMe.pdf file.
The real-time monitoring data exporter is deployed and runs in your data centers. Cloud Monitor cannot ensure the stability of the exporter. Manual O&M is required. If an exception occurs on the exporter, you can provide suggestions to Cloud Monitor. Cloud Monitor shall not be liable for any accidental loss caused.
Benefits:
You can use the real-time data export feature of Hybrid Cloud Monitoring to export monitoring data in streaming mode in a fast and real-time manner. This prevents data loss and imposes no limits on the number of API calls and network bandwidth.
The exporter is deployed locally and requires simple operations.
Monitoring data can be exported from various dimensions. The information such as the instance IP address, instance name, region, resource group, and tag is automatically added. This way, data can be analyzed by using PromQL from multiple dimensions.