Go to file
Joshua Powers 10b5ddb846
fix: do not save cache on i386 builds (#10464)
2022-01-19 10:30:53 -07:00
.circleci fix: do not save cache on i386 builds (#10464) 2022-01-19 10:30:53 -07:00
.github fix: update bug template 2021-12-21 14:03:59 -07:00
agent feat: Parser plugin restructuring (#8791) 2022-01-12 15:54:42 -07:00
assets Mac Packaging / Notarization (#8878) 2021-03-05 10:14:01 -05:00
cmd/telegraf feat: Parser plugin restructuring (#8791) 2022-01-12 15:54:42 -07:00
config feat: check TLSConfig early to catch missing certificates (#10341) 2022-01-18 16:04:09 -06:00
docs feat: Add noise plugin (#10057) 2022-01-12 08:20:33 -07:00
etc feat: update etc/telegraf.conf and etc/telegraf_windows.conf (#10429) 2022-01-12 09:58:47 -06:00
filter Generic SQL input (#8735) 2021-06-15 13:10:52 -06:00
internal fix: snmp input plugin errors if mibs folder doesn't exist (#10346) (#10354) 2022-01-11 15:17:05 -07:00
logger refactor: move from io/ioutil to io and os package (#9811) 2021-09-28 15:16:32 -06:00
metric chore: typos across source code comments (#10361) 2022-01-05 08:20:10 -07:00
models feat: Parser plugin restructuring (#8791) 2022-01-12 15:54:42 -07:00
plugins fix: address flaky tests in cookie_test.go and graylog_test.go (#10326) 2022-01-18 16:55:47 -06:00
scripts feat: add systemd notify support (#10340) 2022-01-05 08:21:14 -07:00
selfstat Remove error return type from metric.New method (#9116) 2021-04-13 14:40:03 -04:00
testutil feat: add mongodb output plugin (#9923) 2021-10-28 14:42:49 -06:00
.gitattributes Fix tests for Windows - part 1 (#8414) 2020-11-23 10:40:32 -05:00
.gitignore fix: gitignore should ignore .toml/.conf files (#9818) 2021-10-01 15:09:50 -06:00
.golangci.yml chore: Forbids "log" package only for aggregators, inputs, outputs, parsers and processors (#10191) 2021-12-03 11:50:51 -06:00
.markdownlint.yml feat: Implement deprecation infrastructure (#10200) 2021-12-01 12:38:43 -07:00
CHANGELOG.md Update changelog 2022-01-05 10:26:48 -07:00
CONTRIBUTING.md docs: remove duplicate links in CONTRIBUTING.md (#10218) 2021-12-06 09:02:05 -07:00
EXTERNAL_PLUGINS.md chore: clean up all markdown lint errors in root directory (#10154) 2021-11-24 11:45:31 -07:00
LICENSE Build packages in makefile (#7759) 2020-06-30 00:15:28 -07:00
Makefile feat: add builds for riscv64 (#10262) 2021-12-22 13:51:11 -07:00
README.md chore: readme escape rpm variables 2022-01-18 16:38:16 -07:00
SECURITY.md chore: clean up all markdown lint errors in root directory (#10154) 2021-11-24 11:45:31 -07:00
TelegrafTiger.png docs: Add logo (#9574) 2021-08-03 15:03:33 -06:00
accumulator.go chore: typos across source code comments (#10361) 2022-01-05 08:20:10 -07:00
aggregator.go add support for streaming processors (#7634) 2020-06-05 10:43:43 -04:00
build_version.txt Update build version to 1.22.0 2021-12-15 15:06:49 -06:00
docker-compose.yml Update pgx to v4 (#9182) 2021-06-02 21:28:16 -06:00
go.mod fix: address flaky tests in cookie_test.go and graylog_test.go (#10326) 2022-01-18 16:55:47 -06:00
go.sum fix: address flaky tests in cookie_test.go and graylog_test.go (#10326) 2022-01-18 16:55:47 -06:00
info.plist Mac Packaging / Notarization (#8878) 2021-03-05 10:14:01 -05:00
input.go add plugin documentation 2020-10-14 12:27:16 -04:00
metric.go Cleanup metric type docs (#9244) 2021-05-20 16:34:07 -04:00
output.go add plugin documentation 2020-10-14 12:27:16 -04:00
parser.go feat: Parser plugin restructuring (#8791) 2022-01-12 15:54:42 -07:00
plugin.go feat: Implement deprecation infrastructure (#10200) 2021-12-01 12:38:43 -07:00
processor.go add plugin documentation 2020-10-14 12:27:16 -04:00

README.md

Telegraf

tiger

Circle CI Docker pulls Slack Status

Telegraf is an agent for collecting, processing, aggregating, and writing metrics. Based on a plugin system to enable developers in the community to easily add support for additional metric collection. There are four distinct types of plugins:

  1. Input Plugins collect metrics from the system, services, or 3rd party APIs
  2. Processor Plugins transform, decorate, and/or filter metrics
  3. Aggregator Plugins create aggregate metrics (e.g. mean, min, max, quantiles, etc.)
  4. Output Plugins write metrics to various destinations

New plugins are designed to be easy to contribute, pull requests are welcomed, and we work to incorporate as many pull requests as possible. Consider looking at the list of external plugins as well.

Minimum Requirements

Telegraf shares the same minimum requirements as Go:

  • Linux kernel version 2.6.23 or later
  • Windows 7 or later
  • FreeBSD 11.2 or later
  • MacOS 10.11 El Capitan or later

Obtaining Telegraf

View the changelog for the latest updates and changes by version.

Binary Downloads

Binary downloads are available from the InfluxData downloads page or from each GitHub Releases page.

Package Repository

InfluxData also provides a package repo that contains both DEB and RPM downloads.

For deb-based platforms (e.g. Ubuntu and Debian) run the following to add the repo key and setup a new sources.list entry:

wget -qO- https://repos.influxdata.com/influxdb.key | sudo tee /etc/apt/trusted.gpg.d/influxdb.asc >/dev/null
source /etc/os-release
echo "deb https://repos.influxdata.com/${ID} ${VERSION_CODENAME} stable" | sudo tee /etc/apt/sources.list.d/influxdb.list
sudo apt-get update && sudo apt-get install telegraf

For RPM-based platforms (e.g. RHEL, CentOS) use the following to create a repo file and install telegraf:

cat <<EOF | sudo tee /etc/yum.repos.d/influxdb.repo
[influxdb]
name = InfluxDB Repository - RHEL $releasever
baseurl = https://repos.influxdata.com/rhel/\$releasever/\$basearch/stable
enabled = 1
gpgcheck = 1
gpgkey = https://repos.influxdata.com/influxdb.key
EOF
sudo yum install telegraf

Build From Source

Telegraf requires Go version 1.17 or newer, the Makefile requires GNU make.

  1. Install Go >=1.17 (1.17.2 recommended)

  2. Clone the Telegraf repository:

    git clone https://github.com/influxdata/telegraf.git
    
  3. Run make from the source directory

    cd telegraf
    make
    

Nightly Builds

Nightly builds are available, generated from the master branch.

3rd Party Builds

Builds for other platforms or package formats are provided by members of theTelegraf community. These packages are not built, tested, or supported by the Telegraf project or InfluxData. Please get in touch with the package author if support is needed:

Getting Started

See usage with:

telegraf --help

Generate a telegraf config file

telegraf config > telegraf.conf

Generate config with only cpu input & influxdb output plugins defined

telegraf --section-filter agent:inputs:outputs --input-filter cpu --output-filter influxdb config

Run a single telegraf collection, outputting metrics to stdout

telegraf --config telegraf.conf --test

Run telegraf with all plugins defined in config file

telegraf --config telegraf.conf

Run telegraf, enabling the cpu & memory input, and influxdb output plugins

telegraf --config telegraf.conf --input-filter cpu:mem --output-filter influxdb

Documentation

Latest Release Documentation

For documentation on the latest development code see the documentation index.

Contributing

There are many ways to contribute: