Monitor Kubernetes cluster using Prometheus + Grafana
kubectl create namespace monitoring
$ helm repo add stable https://kubernetes-charts.storage.googleapis.com
helm repo update
helm install grafana --namespace monitoring stable/grafana
helm install prometheus --namespace monitoring stable/prometheus
export POD_NAME=$(kubectl get pods --namespace monitoring -l "app=prometheus,component=server" -o jsonpath="{.items[0].metadata.name}")
kubectl --namespace monitoring port-forward $POD_NAME 9090
export POD_NAME=$(kubectl get pods --namespace monitoring -l "app=grafana" -o jsonpath="{.items[0].metadata.name}")
kubectl --namespace monitoring port-forward $POD_NAME 3000
# Get "admin" password
kubectl get secret --namespace monitoring grafana -o jsonpath="{.data.admin-password}" | base64 --decode ; echo
Use following URL as Prometheus server url: http://prometheus-server.monitoring.svc.cluster.local
WARNING: Grafana - By default Persistence is disabled !!!