-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Update etcd monitoring procedure #19286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
ec9dbcb
bbf5b7b
fa68424
9bbfadf
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,7 +7,7 @@ | |
|
|
||
| If the `etcd` service does not run correctly, successful operation of the whole {product-title} cluster is in danger. Therefore, it is reasonable to configure monitoring of `etcd`. | ||
|
|
||
| Follow these steps to configure `etcd` monitoring: | ||
| To enable the `etcd` monitoring: | ||
|
|
||
| .Procedure | ||
|
|
||
|
|
@@ -27,68 +27,20 @@ node-exporter-b2mrp 2/2 Running 0 | |
| node-exporter-fd52p 2/2 Running 0 33m | ||
| node-exporter-hfqgv 2/2 Running 0 33m | ||
| prometheus-k8s-0 4/4 Running 1 35m | ||
| prometheus-k8s-1 0/4 ContainerCreating 0 21s | ||
| prometheus-k8s-1 4/4 Runinng 0 35m | ||
| prometheus-operator-6c9fddd47f-9jfgk 1/1 Running 0 36m | ||
| ---- | ||
|
|
||
| . Open the configuration file for the cluster monitoring stack: | ||
| . Set this variable to `true` in the Ansible inventory file: | ||
| + | ||
| ---- | ||
| $ oc -n openshift-monitoring edit configmap cluster-monitoring-config | ||
| ---- | ||
|
|
||
| . Under `config.yaml: |+`, add the `etcd` section. | ||
|
|
||
| .. If you run `etcd` in static pods on your master nodes, you can specify the `etcd` nodes using the selector: | ||
| + | ||
| ---- | ||
| ... | ||
| data: | ||
| config.yaml: |+ | ||
| ... | ||
| etcd: | ||
| targets: | ||
| selector: | ||
| openshift.io/component: etcd | ||
| openshift.io/control-plane: "true" | ||
| ---- | ||
| `openshift_cluster_monitoring_operator_etcd_enabled` | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. if we only set openshift_cluster_monitoring_operator_etcd_enabled=true without setting the kube-etcd-client-certs secret first, we would get error, the prometheus pod will not become running Normal Scheduled 1m default-scheduler Successfully assigned openshift-monitoring/prometheus-k8s-0 to juzhao-311-node-1
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @juzhao not sure to follow your comment. The procedure described here is to setup the etcd monitoring and setting up the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @simonpasquier this is the doc, |
||
|
|
||
| .. If you run `etcd` on separate hosts, you need to specify the nodes using IP addresses: | ||
| . If you run `etcd` on separate hosts, set this variable in the Ansible inventory file to specify the nodes using IP addresses: | ||
| + | ||
| ---- | ||
| ... | ||
| data: | ||
| config.yaml: |+ | ||
| ... | ||
| etcd: | ||
| targets: | ||
| ips: | ||
| - "127.0.0.1" | ||
| - "127.0.0.2" | ||
| - "127.0.0.3" | ||
| ---- | ||
| `openshift_cluster_monitoring_operator_etcd_hosts` | ||
| + | ||
| If the IP addresses for `etcd` nodes change, you must update this list. | ||
|
|
||
| . Verify that the `etcd` service monitor is now running: | ||
| + | ||
| ---- | ||
| $ oc -n openshift-monitoring get servicemonitor | ||
| NAME AGE | ||
| alertmanager 35m | ||
| etcd 1m <1> | ||
| kube-apiserver 36m | ||
| kube-controllers 36m | ||
| kube-state-metrics 34m | ||
| kubelet 36m | ||
| node-exporter 34m | ||
| prometheus 36m | ||
| prometheus-operator 37m | ||
| ---- | ||
| <1> The `etcd` service monitor. | ||
| + | ||
| It might take up to a minute for the `etcd` service monitor to start. | ||
|
|
||
| . Now you can navigate to the web interface to see more information about the status of `etcd` monitoring. | ||
|
|
||
| .. To get the URL, run: | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.