GithubHelp home page GithubHelp logo

monitoring's Introduction

Knative Monitoring

This repository contains Grafana Dashboards and Prometheus Scraping configurations to monitor Knative.

It has been tested with the following configuration:

Also, kube-state-metrics < v2.1 doesn't export all labels by default which means you must pass the following argument to kube-state-metrics:

- --metric-labels-allowlist=pods=[*],deployments=[app.kubernetes.io/name,app.kubernetes.io/component,app.kubernetes.io/instance]

Once kube-state-metrics has been adjusted, you will need to deploy the following servicemonitors and import the dashboards in the grafana folder.

kubectl apply -f https://raw.githubusercontent.com/knative-sandbox/monitoring/main/servicemonitor.yaml

monitoring's People

Contributors

grantr avatar upodroid avatar kariya-mitsuru avatar dprotaso avatar zchenyu avatar prushh avatar eloyekunle avatar evankanderson avatar mattmoor avatar rhuss avatar kahirokunn avatar yechuan51 avatar

Stargazers

jong-un avatar Wajeeh Ul Hassan avatar Ilker Ispir avatar KimJohn Quinn avatar  avatar michael xu avatar Jooho Lee avatar thisiz_A avatar Konstantin avatar Pouria Taj avatar  avatar Henrique Lucas França avatar Hans-Jörg Wieland avatar Caleb Woodbine avatar HIGASHI Taiju avatar Joke de Buhr avatar Dmitry Kozlov avatar Murugappan Chetty avatar

Watchers

 avatar salaboy avatar Chris Suszynski avatar James Cloos avatar Zhimin Xiang avatar Stavros Kontopoulos avatar Nader Ziada avatar April Kyle Nassi avatar Reto Lehmann avatar

monitoring's Issues

Label value shows None

This needs to be label_values(controller_reconcile_count{reconciler=~".+"}, reconciler) otherwise template variable shows None. Here is after the fix:

image

Notice however that there is panel row named Row title which has zero panels in, needs to be removed.

Originally posted by @skonto in #1 (comment)

kube-prometheus-stack and Grafana dashboards

Hi,

I think I followed the docs correctly, however Knative dashboads do not show up in Grafana after applying https://raw.githubusercontent.com/knative-sandbox/monitoring/main/grafana/dashboards.yaml (cf. https://github.com/knative-sandbox/monitoring/tree/main/grafana).

Note that I can import the JSON files by hand and get working dashboards. I'd like to be able to automate that part.

Here is my procedure:

# Install the Prometheus Operator through Helm
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo update
helm install prometheus prometheus-community/kube-prometheus-stack -n default -f values.yaml

# Apply the ServiceMonitors/PodMonitors to collect metrics from Knative
kubectl apply -f https://raw.githubusercontent.com/knative-sandbox/monitoring/main/servicemonitor.yaml

# Import Knative Grafana dashboards
kubectl apply -f https://raw.githubusercontent.com/knative-sandbox/monitoring/main/grafana/dashboards.yaml

Here are the contents of my values.yaml file:

kube-state-metrics:
  metricLabelsAllowlist:
   - pods=[*]
   - deployments=[app.kubernetes.io/name,app.kubernetes.io/component,app.kubernetes.io/instance]
prometheus:
  prometheusSpec:
    serviceMonitorSelectorNilUsesHelmValues: false
    podMonitorSelectorNilUsesHelmValues: false
grafana:
  sidecar:
    dashboards:
      enabled: true
      searchNamespace: ALL

Any help would be appreciated.

Thanks!

Recent changes that caused metrics collection to fail

Hi, I believe a recent PR: #21 have caused the prometheus metrics collection to fail.

I was following the instruction on https://knative.dev/docs/eventing/observability/metrics/collecting-metrics/ but then I realized that the knative metrics do not appear on the dashboard. After hours of debugging, I noticed that the service monitors have configured their port to "metrics", but the actual services(i.e. activator), exposes their metrics on a port with "http-metrics".

I was able to get the metrics collected by manually patching the monitor with the correct port.

@zchenyu

When there are no requests it prints no namespace for the template variable:

When there are no requests it prints no namespace for the template variable:
image
However I had a service running without any requests hitting it. Namespace could cover this case too if i was based on (not a big issue), probably we should list the service and show no data as before:

"query": "label_values(kube_pod_labels{label_serving_knative_dev_configuration=~\".+\"}, namespace)",
          

Originally posted by @skonto in #1 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.