Configuring Service Discovery for CCE Clusters
By adding ServiceMonitor or PodMonitor, you can configure Prometheus collection rules to monitor the applications deployed in CCE clusters.
Prerequisite
Both your service and CCE cluster have been connected to a Prometheus instance for CCE. For details, see Prometheus Instance for CCE.
Precautions
To view the kube-prometheus-stack status, log in to the CCE console and access the cluster page, choose Add-ons in the navigation pane, and locate that add-on on the right.
Adding ServiceMonitor
- Log in to the AOM 2.0 console.
- In the navigation pane on the left, choose Metric Analysis > Prometheus Monitoring.
- In the instance list, click a Prometheus instance for CCE.
- In the navigation pane on the left, choose Service Discovery. On the Settings tab page, click ServiceMonitor.
- Click Add ServiceMonitor. In the displayed dialog box, set related parameters and click OK.
After the configuration is complete, the new collection rule is displayed in the service discovery list.
Adding PodMonitor
- Log in to the AOM 2.0 console.
- In the navigation pane on the left, choose Metric Analysis > Prometheus Monitoring.
- In the instance list, click a Prometheus instance for CCE.
- In the navigation pane on the left, choose Service Discovery. On the Settings tab page, click PodMonitor.
- Click Add PodMonitor. In the displayed dialog box, set related parameters and click OK.
After the configuration is complete, the new collection rule is displayed in the service discovery list.
More Operations
Perform the operations listed in Table 1 if needed.
Operation |
Description |
---|---|
Viewing service discovery |
|
Enabling or disabling collection rules |
On the Settings tab page of the Service Discovery page, click in the Status column to enable or disable collection rules. indicates that collection rules are disabled. indicates that collection rules are enabled. |
Deleting service discovery |
Click in the Operation column. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot