README.md 3.92 KB
Newer Older
kelseiv's avatar
kelseiv committed
1
# Telegraf-DS (DaemonSet) Helm chart
2

kelseiv's avatar
kelseiv committed
3
[Telegraf](https://github.com/influxdata/telegraf) is a plugin-driven server agent used for collecting and reporting metrics. This chart runs a DaemonSet of Telegraf instances to collect host-level metrics for your cluster. To poll individual instances of infrastructure or APIs, use the [Telegraf chart](https://github.com/influxdata/helm-charts/tree/master/charts/telegraf).
4

kelseiv's avatar
kelseiv committed
5
The Telegraf-DS Helm chart uses the [Helm](https://helm.sh) package manager to bootstrap a Telegraf-DS (DaemonSet) on a [Kubernetes](http://kubernetes.io) cluster. You cannot customize Telegraf inputs for this chart being the goal is to provide an opinionated configuration for monitoring Kubernetes nodes and global Kubernetes monitoring.
6

kelseiv's avatar
kelseiv committed
7 8 9 10 11 12
## Prerequisites

- Helm v2 or later
- Kubernetes 1.11+ with Beta APIs enabled

## QuickStart
13 14

```console
15
helm repo add influxdata https://helm.influxdata.com/
16
helm upgrade --install telegraf-ds influxdata/telegraf-ds
17 18
```

kelseiv's avatar
kelseiv committed
19
> **Tip**: `helm upgrade --install [RELEASE] [CHART] [FLAGS]` is idempotent and can be run multiple times. If chart hasn't been installed, Helm installs it. If chart is installed, Helm redeploys the same version or upgrades the chart if a new version is available.
20

kelseiv's avatar
kelseiv committed
21
## Install the chart
22 23 24 25

To install the chart with the release name `my-release`:

```console
26
helm upgrade --install my-release influxdata/telegraf-ds
27 28
```

29
The command deploys a Telegraf DaemonSet on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section as well as the [values.yaml](/values.yaml) file lists the parameters that can be configured during installation.
30

kelseiv's avatar
kelseiv committed
31
> **Tip**: To view all Helm chart releases, run `helm list`.
32

kelseiv's avatar
kelseiv committed
33
## Uninstall the chart
34 35 36 37

To uninstall/delete the `my-release` deployment:

```console
38
helm uninstall my-release
39 40 41 42
```

The command removes all the Kubernetes components associated with the chart and deletes the release.

kelseiv's avatar
kelseiv committed
43
## Configure the chart
44

kelseiv's avatar
kelseiv committed
45
The default configuration parameters are listed in `values.yaml`. To change the defaults, specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example:
46 47

```console
48
helm upgrade --install my-release \
49 50 51 52
  --set config.outputs.influxdb.url=http://foo.bar:8086 \
    influxdata/telegraf-ds
```

kelseiv's avatar
kelseiv committed
53
This command lets the chart deploy by setting the InfluxDB URL for Telegraf to write to.
54 55 56 57

Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,

```console
58
helm upgrade --install my-release -f values.yaml influxdata/telegraf-ds
59 60
```

61 62
> **Tip**: `helm upgrade --install [RELEASE] [CHART] [FLAGS]` can be shortened : `helm upgrade -i [RELEASE] [CHART] [FLAGS]`

kelseiv's avatar
kelseiv committed
63
## Telegraf configuration
64 65 66

This chart deploys the following by default:

67
- `telegraf` running as a DaemonSet (`telegraf-ds`) with the following plugins enabled
68 69 70 71 72 73 74
  * [`cpu`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/cpu)
  * [`disk`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/disk)
  * [`diskio`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/diskio)
  * [`docker`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/docker)
  * [`kernel`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/kernel)
  * [`kubernetes`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/kubernetes)
  * [`mem`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/mem)
75
  * [`net`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/net)
76 77 78
  * [`processes`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/processes)
  * [`swap`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/swap)
  * [`system`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/system)
79 80 81 82

The following plugin can be enable through the configuration:

- [`internal`](https://github.com/influxdata/telegraf/tree/master/plugins/inputs/internal)