Commit Graph
109 Commits
Author SHA1 Message Date
paulfantom 1a67ab3655 jsonnet: annotate default container for node-exporter DS
Signed-off-by: paulfantom <pawel@krupa.net.pl>
2021-10-25 16:31:12 +02:00
paulfantom ade451bf04 jsonnet: refactor grafana component to include new kubernetes-grafana library 2021-10-20 19:24:39 +02:00
machinly ce7007c568 add grafana ldap support 2021-10-18 15:33:06 +03:00
Paweł Krupa d0464b2bde Merge pull request #1376 from rajaSahil/Update-Configuration 2021-10-12 14:17:35 +02:00
Markus Heinemann f1cff459de fix: upgrade deprecated policy/v1beta1 kubernetes api 2021-10-12 09:00:09 +00:00
Sahil Raja cbef68e090 Addressed review comments
Signed-off-by: Sahil Raja <sahilraja242@gmail.com>
2021-10-12 09:01:45 +05:30
Sahil Raja ae89cad60d Made node-exporter args configurable
Signed-off-by: Sahil Raja <sahilraja242@gmail.com>
2021-10-12 09:00:00 +05:30
Haoyu Sun b6c97fc6c0 remove "app" label selector deprecated by prometheus-operator 2021-10-05 19:59:39 +02:00
Damien Grisonnet 374413f10a Merge pull request #1409 from dgrisonnet/drop-pa-metrics
Drop some of the metrics exposed by prometheus-adapter
2021-09-30 17:45:15 +02:00
Damien Grisonnet 5ebbb65276 jsonnet: drop some of prometheus-adapter metrics
The current implementation of prometheus-adapter exposes a lot of
metrics about the health of its aggregated apiserver. The issue is that
the some of these metrics are not very useful in the context of
prometheus-adapter, and we currently can't avoid exposing them since
they are registered to the Kubernetes global Prometheus registry. Until
this is improved in upstream Kubernetes, we could benefit from dropping
some of the metrics that are not very useful.

Before this change, in a default kube-prometheus installation, we would
have 800+ series for prometheus-adapter against 400+, so we divided the
number of series by two will focusing on the most valuable metrics for
prometheus-adapter.

Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com>
2021-09-29 13:02:00 +02:00
Jan Fajerski 6fa097c0ed jsonnet/node-exporter: adjust to node-exporter v1.2.0 arg name change
In version [node-exporter v1.2.0](https://github.com/prometheus/node_exporter/releases/tag/v1.2.0)
two argument name changes were introduced. While the old names still
work (with a deprecation warning), lets use the new names.

Signed-off-by: Jan Fajerski <jfajersk@redhat.com>
2021-09-29 11:15:10 +02:00
Philip Gough 58e2c131c2 Keep 'container_fs_.*' metrics from cAdvisor 2021-09-27 17:13:00 +01:00
Arunprasad Rajkumar c5d265a14e thanos: bump to latest and add thanosPrometheusCommonDimensions
This commit pulls latest changes from thanos mixins and sets `thanosPrometheusCommonDimensions`
to `namespace, pod` for k8s use case.

Refer https://github.com/thanos-io/thanos/pull/4508 for more details.

Signed-off-by: Arunprasad Rajkumar <arajkuma@redhat.com>
2021-09-27 12:07:08 +05:30
Philip Gough 56f96e6389 Adjust dropped metrics from cAdvisor
This change drops pod-centric metrics without a non-empty 'container' label.

Previously we dropped pod-centric metrics without a (pod, namespace) label set
however these can be critical for debugging.
2021-09-24 17:24:01 +01:00
Damien Grisonnet 7f1092cdde Merge pull request #1344 from PhilipGough/MON-1085
jsonnet: Support scraping the config-reloader for AlertManager and Pr…
2021-09-22 16:16:48 +02:00
Philip Gough 7b32afb8aa jsonnet: Support scraping the config-reloader for AlertManager and Prometheus 2021-09-22 14:54:12 +01:00
Sylvain Pasche 6d5c1b793c Always generate grafana-config secret
Since https://github.com/brancz/kubernetes-grafana/pull/115, upstream
grafana contains a non-empty config. Generate the grafana-config secret
unconditionally even if no user config is passed.
2021-09-16 14:25:53 +02:00
Arunprasad Rajkumar 4de44139ec add comments to reason fsSpaceFilling threshold adjustment
Signed-off-by: Arunprasad Rajkumar <arajkuma@redhat.com>
2021-09-02 17:38:02 +05:30
Arunprasad Rajkumar 03471fd86f Adjust threshold for SpaceFillingUp warning alert
Reduce threshold of NodeFilesystemSpaceFillingUp warning alert to 20% space available, instead of 40% (default).

This will align the threshold according to default kubelet GC values
below[1],

"imageMinimumGCAge": "2m0s",
"imageGCHighThresholdPercent": 85,
"imageGCLowThresholdPercent": 80,

[1] https://kubernetes.io/docs/reference/config-api/kubelet-config.v1beta1/

Signed-off-by: Arunprasad Rajkumar <arajkuma@redhat.com>
2021-09-01 13:29:36 +05:30
paulfantom c4113807fb jsonnet: set thanos config to null by default
Signed-off-by: paulfantom <pawel@krupa.net.pl>
2021-08-16 15:16:52 +02:00
Dimitrije Manic 12cd7fd9ce Prometheus ruleSelector defaults to all rules 2021-08-11 10:16:24 -04:00
Damien Grisonnet 33cc694f18 Merge pull request #1308 from PaytmLabs/feature/separate-thanos-rules
Create Thanos Sidecar rules separately from Prometheus ones
2021-08-05 16:19:01 +02:00
Maxime Brunet 961f138dd0 Add back _config.runbookURLPattern for Thanos Sidecar rules 2021-08-04 14:22:06 -07:00
Paweł Krupa e931a417fc Merge pull request #1230 from Luis-TT/fix-kube-proxy-dashboard 2021-08-04 09:55:09 +02:00
Luis Vidal Ernst 0b49c3102d Added PodMonitor for kube-proxy 2021-08-03 08:31:49 +02:00
Maxime Brunet 0e7dc97bc5 Create Thanos Sidecar rules separately from Prometheus ones 2021-08-02 12:46:06 -07:00
Paweł Krupa b9c73c7b29 Merge pull request #1283 from prashbnair/node-veth
changing node exporter ignore list
2021-07-28 09:17:03 +02:00
Prashant Balachandran 09fdac739d changing node exporter ignore list 2021-07-27 17:17:19 +05:30
Paweł Krupa 785789b776 Merge pull request #1257 from Luis-TT/kube-state-metrics-kubac-proxy-resources 2021-07-27 12:36:26 +02:00
lanmarti ed48391831 Add resource requests and limits to prometheus-adapter container 2021-07-27 12:19:51 +02:00
Manuel Rüger acd1eeba4c node.libsonnet: Fix small typo
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2021-07-22 19:14:24 +02:00
paulfantom cfe830f8f0 jsonnet/kube-prometheus: point to runbooks.prometheus-operator.dev
Signed-off-by: paulfantom <pawel@krupa.net.pl>
2021-07-22 17:30:57 +02:00
Luis Vidal Ernst 9c638162ae Allow customizing of kubeRbacProxy in kube-state-metrics 2021-07-21 13:57:05 +02:00
Paweł Krupa acea5efd85 Merge pull request #1268 from paulfantom/alerts-best-practices
Alerts best practices
2021-07-21 09:32:32 +02:00
Philip Gough 463ad065d3 jsonnet: Drop cAdvisor metrics with no (pod, namespace) labels while preserving ability to monitor system services resource usage
The following provides a description and cardinality estimation based on the tests in a local cluster:

container_blkio_device_usage_total - useful for containers, but not for system services (nodes*disks*services*operations*2)
container_fs_.*                    - add filesystem read/write data (nodes*disks*services*4)
container_file_descriptors         - file descriptors limits and global numbers are exposed via (nodes*services)
container_threads_max              - max number of threads in cgroup. Usually for system services it is not limited (nodes*services)
container_threads                  - used threads in cgroup. Usually not important for system services (nodes*services)
container_sockets                  - used sockets in cgroup. Usually not important for system services (nodes*services)
container_start_time_seconds       - container start. Possibly not needed for system services (nodes*services)
container_last_seen                - Not needed as system services are always running (nodes*services)
container_spec_.*                  - Everything related to cgroup specification and thus static data (nodes*services*5)
2021-07-20 12:50:02 +01:00
paulfantom 46eb1713a5 jsonnet: remove unused alert unit tests as those are moved to alertmanager repository 2021-07-20 11:14:38 +02:00
paulfantom 8c357c6bde jsonnet: align alert annotations with best practices
Signed-off-by: paulfantom <pawel@krupa.net.pl>
2021-07-20 10:59:49 +02:00
Paweł Krupa 80bb15bedd Merge pull request #1255 from yeya24/fix-dashboards-definition-length-check 2021-07-19 09:56:09 +02:00
Yury Gargay 9b08b941f8 Update kubernetes-mixin
From https://github.com/kubernetes-monitoring/kubernetes-mixin/commit/b710a868a95621aa93e0b661954f63f4db82aaea
2021-07-14 18:51:36 +02:00
ben.ye 43adca8df7 fmt again
Signed-off-by: ben.ye <ben.ye@bytedance.com>
2021-07-13 19:56:38 -07:00
ben.ye 90b2751f06 fmt code
Signed-off-by: ben.ye <ben.ye@bytedance.com>
2021-07-13 19:48:01 -07:00
ben.ye dee7762ae3 create dashboardDefinitions if rawDashboards or folderDashboards are specified
Signed-off-by: ben.ye <ben.ye@bytedance.com>
2021-07-13 19:39:01 -07:00
Damien Grisonnet 97e77e9996 Merge pull request #1231 from dgrisonnet/fix-adapter-queries
Consolidate intervals used in prometheus-adapter CPU queries
2021-07-07 13:48:02 +02:00
Damien Grisonnet b9563b9c2d jsonnet: improve adapter queries readability
Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com>
2021-07-05 15:29:45 +02:00
Damien Grisonnet 8812e45501 jsonnet: readjust prometheus-adapter intervals
Previously, prometheus-adapter configuration wasn't taking into account
the scrape interval of kubelet, node-exporter and windows-exporter
leading to getting non fresh results, and even negative results from the
CPU queries when the irate() function was extrapolating data.
To fix that, we want to set the interval used in the irate() function in
the CPU queries to 4x scrape interval in order to extrapolate data
between the last two scrapes. This will improve the freshness of the cpu
usage exposed and prevent incorrect extrapolations.

Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com>
2021-07-05 15:28:25 +02:00
Sunil Thaha 0280f4ddf9 jsonnet: kube-prometheus adapt to changes to veth interfaces names
With OVN, the container veth network interface names that used to start
with `veth` has now changed to `<rand-hex>{15}@if<number>`(see Related
Links below).

This patch adapts to the new change introduced in ovn and ignores the network
interfaces that match `[a-z0-9]{15}@if\d+` in addition to those starting
with `veth`

Related Links:
  - https://github.com/openshift/ovn-kubernetes/blob/master/go-controller/vendor/github.com/containernetworking/plugins/pkg/ip/link_linux.go#L107
  - https://github.com/openshift/ovn-kubernetes/blob/master/go-controller/pkg/cni/helper_linux.go#L148

Signed-off-by: Sunil Thaha <sthaha@redhat.com>
2021-07-01 12:01:19 +10:00
fpetkovski 0ff173efea jsonnet: disable insecure cypher suites for prometheus-adapter
Running sslscan against the prometheus adapter secure port reports two
insecure SSL ciphers, ECDHE-RSA-DES-CBC3-SHA and DES-CBC3-SHA.

This commit removes those ciphers from the list.

Signed-off-by: fpetkovski <filip.petkovsky@gmail.com>
2021-06-22 14:17:09 +02:00
paulfantom 5ea10d80a1 jsonnet: fix label selector for coredns ServiceMonitor 2021-06-11 10:56:54 +02:00
anarcher 8bcfb98a1d feat(grafana): add env parameter for gradana component 2021-05-31 18:52:55 +09:00
Prem Saraswat 228f8ffdad Add support for feature-flags in Prometheus 2021-05-27 23:21:30 +05:30