1. Executive Summary
CloudPE Kubernetes clusters support integrated monitoring, giving you built-in metrics collection, alerting, and visualization without deploying a separate monitoring stack.
- Enabled by setting the
monitoring_enabled=truelabel during cluster deployment. - Provides cluster-level and node-level metrics out of the box.
- β No manual installation of Prometheus/Grafana is required if enabled at creation time.
2. Prerequisites
Before starting, ensure the following:
βΈοΈ Cluster Requirement
- A Kubernetes cluster with integrated monitoring enabled must already exist.
- See βCreating and Deleting Kubernetes Clustersβ for details.
π» Local Tooling
- The
kubectlCLI must be installed and configured on your client machine. - You must be able to download the clusterβs
.kubeconfigfile from the self-service panel.
3. Monitoring Stack Overview
When integrated monitoring is enabled, the following components are installed automatically:
π Prometheus (Data Collection, Storage, Search)
- node-exporter β exposes server-level and OS-level metrics.
- kube-state-metrics β generates metrics on the state of Kubernetes objects.
π Alertmanager
- Handles alarm aggregation, processing, and dispatch.
π Grafana
- Provides metrics visualization dashboards.
- Accessible in-cluster at
magnum-grafana.kube-system.svc.cluster.local:80.
- Accessible in-cluster at
π Metrics Endpoints
- Kubernetes object-state metrics are exposed at:
magnum-kube-state-metrics.kube-system.svc.cluster.local:8080/metrics
- These can be scraped by Prometheus itself or by any Prometheus-compatible scraper.
π‘ For configuring custom Alertmanager/Prometheus instances, refer to the kube-prometheus documentation. For the full list of exposed metrics, refer to the kube-state-metrics documentation.
4. Accessing the Grafana Dashboards
πΉ Phase A: Get Cluster Access
- On the Kubernetes clusters screen, click the target cluster.
- Click Download kubeconfig to save the
.kubeconfigfile to your client machine. - Install and configure
kubectlon your client machine (see official Kubernetes documentation). - Point
kubectlat your cluster:
export KUBECONFIG=<path_to_kubeconfig>
πΉ Phase B: Verify the Monitoring Stack
- Confirm the kube-prometheus stack is running:
kubectl --namespace kube-system get pods -l "release=magnum"
Expected output (pod names/counts may vary):
NAME READY STATUS RESTARTS AGE
magnum-kube-prometheus-sta-operator-85f757c5dc-ckllb 1/1 Running 0 3d17h
magnum-kube-state-metrics-5cc46cbc5f-tclcv 1/1 Running 0 3d17h
magnum-prometheus-node-exporter-99kfc 1/1 Running 0 3d3h
magnum-prometheus-node-exporter-gwgzr 1/1 Running 0 3d17h
magnum-prometheus-node-exporter-q2pm2 1/1 Running 0 3d17h
magnum-prometheus-node-exporter-sqsl7 1/1 Running 0 2d22h
πΉ Phase C: Retrieve the Grafana Admin Password
- Get the auto-generated
adminpassword:
kubectl get secret --namespace kube-system magnum-grafana \
-o jsonpath="{.data.admin-password}" | base64 --decode ; echo
πΉ Phase D: Port-Forward and Log In
- Forward the Grafana service port to your local machine:
kubectl --namespace kube-system port-forward service/magnum-grafana 3000:80
- Open
http://localhost:3000in your browser and log in asadminusing the password from step 6. - In the left menu, go to Dashboards β Browse, and select the dashboard you want to view.
5. Accessing the Prometheus UI
πΉ Phase A: Set Up Access
- On the Kubernetes clusters screen, click the target cluster.
- Click Download kubeconfig to save the
.kubeconfigfile. - Install and configure
kubectlon your client machine. - Point
kubectlat your cluster:
export KUBECONFIG=<path_to_kubeconfig>
πΉ Phase B: Port-Forward Prometheus
- Forward the Prometheus service port:
kubectl --namespace kube-system port-forward service/magnum-kube-prometheus-sta-prometheus 9090
- Use the following endpoints in your browser:
| URL | Purpose |
|---|---|
http://localhost:9090/graph | Prometheus expression browser and graphing |
http://localhost:9090/metrics | List of exported metrics |
http://localhost:9090/alerts | View configured alerting rules |
6. Accessing the Alertmanager UI
πΉ Phase A: Set Up Access
- On the Kubernetes clusters screen, click the target cluster.
- Click Download kubeconfig to save the
.kubeconfigfile. - Install and configure
kubectlon your client machine. - Point
kubectlat your cluster:
export KUBECONFIG=<path_to_kubeconfig>
πΉ Phase B: Port-Forward Alertmanager
- Forward the Alertmanager service port:
kubectl --namespace kube-system port-forward service/magnum-kube-prometheus-sta-alertmanager 9093
- Open
http://localhost:9093to access the Alertmanager UI.
7. Safety & Recovery
π Experimental Feature Notice
- This monitoring stack is experimental β do not rely on it as the sole monitoring solution in production clusters.
β οΈ Port-Forward Sessions
kubectl port-forwardsessions are tied to your terminal session and stop when the terminal closes or the connection drops.- Only one local port can be forwarded at a time per command; use different local ports if forwarding multiple services simultaneously.
π Best Practice
- Rotate/change the default Grafana
adminpassword after first login if the dashboard will be used regularly. - Restrict access to the
.kubeconfigfile, since it grants full API access to the cluster.
β Summary
- Integrated monitoring (Prometheus, Alertmanager, Grafana) is available on clusters created with
monitoring_enabled=true. - Requires:
- Downloaded
.kubeconfigfile kubectlinstalled and configured locally- Port-forwarding to reach Grafana, Prometheus, or Alertmanager UIs
- Downloaded
- Grafana:
localhost:3000Β· Prometheus:localhost:9090Β· Alertmanager:localhost:9093 - Feature is experimental β not for production use.