Skip to content

Commit ce5761b

Browse files
committed
Update Blog “kubernetes-monitoring-using-prometheus-and-grafana-in-hpe-greenlake-for-private-cloud-enterprise”
1 parent a791fa0 commit ce5761b

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

content/blog/kubernetes-monitoring-using-prometheus-and-grafana-in-hpe-greenlake-for-private-cloud-enterprise.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Before starting, make sure you meet the following requirements:
3939

4040
### Deeploy Prometheus and Grafana using Terraform
4141

42+
4243
Apart from using the HPE GreenLake *hpegl* provider, it also uses the *helm* provider from Hashicorp to deploy both Prometheus and Grafana to the K8s cluster.
4344

4445
#### Terraform config
@@ -119,7 +120,7 @@ resource "helm_release" "grafana-dashboard" {
119120

120121
set {
121122
name = "persistence.enabled"
122-
value = "false"
123+
value = "true"
123124
}
124125
}
125126
```
@@ -128,9 +129,9 @@ There a few things need to point out in above config file.
128129

129130
<style> li { font-size: 100%; line-height: 23px; max-width: none; } </style>
130131

131-
* In both Prometheus and Grafana, the persistence by default is disabled. In case the Prometheus and Grafana pods get terminated for some reason, you will lose all your data. In production deployment, such as HPE GreenLake for Containers, this needs to be enabled to prevent any data lose, *persistence.enabled: true*
132-
* In Prometheus, the DaemonSet deployment of the Node Exporter is trying to mount the *hostPath* volume to the container root “/”, which violates against one deployed OPA (Open Policy Agent) policy to the K8s cluster for FS mount protections. Therefore, the DaemonSet deployment will never be ready, keep showing the warning events as *Warning FailedCreate daemonset-controller Error creating: admission webhook "soft-validate.hpecp.hpe.com" denied the request: Hostpath ("/") referenced in volume is not valid for this namespace because of FS Mount protections.*. You need disable the *hostRootFsMount*, together with *hostNetwork* and *hostPID*.
133-
* Both Prometheus and Grafana services are deployed as *NodePort* service type. Those services will be automatically mapped to the gateway host with assigned ports for easy acces
132+
* In Grafana, the persistence by default is disabled. In case Grafana pod gets terminated for some reason, you will lose all your data. In production deployment, such as HPE GreenLake for Containers, this needs to be enabled, by setting *persistence.enabled* as *true*, to prevent any data lose.
133+
* In Prometheus, the *DaemonSet* deployment of the node exporter is trying to mount the *hostPath* volume to the container root “/”, which violates against one deployed OPA (Open Policy Agent) policy to the K8s cluster for FS mount protections. Therefore, the DaemonSet deployment will never be ready, keep showing the warning events as *Warning FailedCreate daemonset-controller Error creating: admission webhook "soft-validate.hpecp.hpe.com" denied the request: Hostpath ("/") referenced in volume is not valid for this namespace because of FS Mount protections.*. You need disable the *hostRootFsMount*, together with *hostNetwork* and *hostPID*, to comply with the security policy in the cluster.
134+
* Both Prometheus and Grafana services are deployed as *NodePort* service types. Those services will be automatically mapped to the gateway host with assigned ports for easy access.
134135

135136
#### Terraform run
136137

0 commit comments

Comments
 (0)