import OverviewProm from "../partials/monitoring/_overview-prom.mdx"
This topic describes how to monitor applications and clusters with Prometheus in existing cluster installations with Replicated KOTS.
For information about how to access Prometheus, Grafana, and Alertmanager, see Accessing Dashboards Using Port Forwarding.
For information about consuming Prometheus metrics externally in kURL installations, see Consuming Prometheus Metrics Externally.
For existing cluster installations with KOTS, users can install Prometheus in the cluster and then connect the Admin Console to the Prometheus endpoint to enable monitoring.
Replicated recommends that you use CoreOS's Kube-Prometheus distribution for installing and configuring highly available Prometheus on an existing cluster. For more information, see the kube-prometheus GitHub repository.
This repository collects Kubernetes manifests, Grafana dashboards, and Prometheus rules combined with documentation and scripts to provide easy to operate end-to-end Kubernetes cluster monitoring with Prometheus using the Prometheus Operator.
To install Prometheus using the recommended Kube-Prometheus distribution:
-
Clone the kube-prometheus repository to the device where there is access to the cluster.
-
Use
kubectl
to create the resources on the cluster:# Create the namespace and CRDs, and then wait for them to be available before creating the remaining resources kubectl create -f manifests/setup until kubectl get servicemonitors --all-namespaces ; do date; sleep 1; echo ""; done kubectl create -f manifests/
For advanced and cluster-specific configuration, you can customize Kube-Prometheus by compiling the manifests using jsonnet. For more information, see the jsonnet website.
For more information about advanced Kube-Prometheus configuration options, see Customizing Kube-Prometheus in the kube-prometheus GitHub repository.
To view graphs on the Admin Console dashboard, provide the address of a Prometheus instance installed in the cluster.
To connect the Admin Console to a Prometheus endpoint: