From 8ab0a6e2add1a9e40350a32b6e709bdc87eb4080 Mon Sep 17 00:00:00 2001 From: Jerome Meyer Date: Thu, 30 Jan 2020 11:41:57 -0500 Subject: [PATCH 0001/1448] Added externalURL and pathPrefix functions to Template reference documentation Signed-off-by: Jerome Meyer --- docs/configuration/template_reference.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/configuration/template_reference.md b/docs/configuration/template_reference.md index fe2b60b2337..475946923bf 100644 --- a/docs/configuration/template_reference.md +++ b/docs/configuration/template_reference.md @@ -82,6 +82,8 @@ versions. | args | []interface{} | map[string]interface{} | This converts a list of objects to a map with keys arg0, arg1 etc. This is intended to allow multiple arguments to be passed to templates. | | tmpl | string, []interface{} | nothing | Like the built-in `template`, but allows non-literals as the template name. Note that the result is assumed to be safe, and will not be auto-escaped. Only available in consoles. | | safeHtml | string | string | Marks string as HTML not requiring auto-escaping. | +| externalURL | none | string | The URL under which Prometheus is externally reachable (set with `--web.external-url`). | +| pathPrefix | none | string | Path portion of the external URL. | ## Template type differences From 8f33b8bd2cdbe6a59705773e86ea84bd28325b7c Mon Sep 17 00:00:00 2001 From: shoce Date: Mon, 18 Oct 2021 22:43:31 +0530 Subject: [PATCH 0002/1448] Add instructions how to persist prometheus docker container data Signed-off-by: shoce --- docs/installation.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/installation.md b/docs/installation.md index 592d67b28e7..36ff61b3607 100644 --- a/docs/installation.md +++ b/docs/installation.md @@ -55,6 +55,23 @@ docker run \ prom/prometheus ``` +### Save your Prometheus data + +Prometheus data is stored in `/prometheus` dir inside the container, so the data is cleared every time the container gets restarted. To save your data, you need to set up persistent storage (or bind mounts) for your container. + +Run Prometheus container with persistent storage: + +```bash +# Create persistent volume for your data +docker volume create prometheus-data +# Start Prometheus container +docker run \ + -p 9090:9090 \ + -v /path/to/prometheus.yml:/etc/prometheus/prometheus.yml \ + -v prometheus-data:/prometheus \ + prom/prometheus +``` + ### Custom image To avoid managing a file on the host and bind-mount it, the From 690d5d0b5122a041706cecaf3e7c56651b5cc398 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Thu, 2 Sep 2021 13:55:40 +0300 Subject: [PATCH 0003/1448] consoles: exclude iowait and steal from CPU Utilisation 'iowait' and 'steal' indicate specific idle/wait states, which shouldn't be counted into CPU Utilisation. Also see https://github.com/prometheus-operator/kube-prometheus/pull/796 and https://github.com/kubernetes-monitoring/kubernetes-mixin/pull/667. Per the iostat man page: %idle Show the percentage of time that the CPU or CPUs were idle and the system did not have an outstanding disk I/O request. %iowait Show the percentage of time that the CPU or CPUs were idle during which the system had an outstanding disk I/O request. %steal Show the percentage of time spent in involuntary wait by the virtual CPU or CPUs while the hypervisor was servicing another virtual processor. Signed-off-by: Julian Wiedmann --- consoles/node-cpu.html | 2 +- consoles/node-overview.html | 2 +- consoles/node.html | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/consoles/node-cpu.html b/consoles/node-cpu.html index d6c515d2dd0..284ad738f2b 100644 --- a/consoles/node-cpu.html +++ b/consoles/node-cpu.html @@ -47,7 +47,7 @@

CPU Usage