<commit_before>---
title: Configuring Telegraf

menu:
  telegraf_1_13:
    name: Configuring
    weight: 20
    parent: Administration
---

The Telegraf configuration file (`telegraf.conf`) lists all of the available plugins. The current version is available here:
[telegraf.conf](https://github.com/influxdata/telegraf/blob/master/etc/telegraf.conf)

## Generating a Configuration File

A default Telegraf configuration file can be auto-generated by Telegraf:

```
telegraf config > telegraf.conf
```

To generate a configuration file with specific inputs and outputs, you can use the
`--input-filter` and `--output-filter` flags:

```
telegraf --input-filter cpu:mem:net:swap --output-filter influxdb:kafka config
```

## Configuration file locations

The location of the configuration file can be set via the `--config` command
line flag.

When the `--config-directory` command line flag is used, files ending with<commit_msg>update header<commit_after>---
title: Configuring Telegraf

menu:
  telegraf_1_13:
    name: Configuring
    weight: 20
    parent: Administration
---

The Telegraf configuration file (`telegraf.conf`) lists all of the available plugins. The current version is available here:
[telegraf.conf](https://github.com/influxdata/telegraf/blob/master/etc/telegraf.conf)

## Generate a configuration file

A default Telegraf configuration file can be auto-generated by Telegraf:

```
telegraf config > telegraf.conf
```

To generate a configuration file with specific inputs and outputs, you can use the
`--input-filter` and `--output-filter` flags:

```
telegraf --input-filter cpu:mem:net:swap --output-filter influxdb:kafka config
```

## Configuration file locations

The location of the configuration file can be set via the `--config` command
line flag.

When the `--config-directory` command line flag is used, files ending with
{'fraction_non_alphanumeric': 0.0980603448275862, 'fraction_numerical': 0.005387931034482759, 'mean_word_length': 4.4298245614035086, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '931927', 'n_tokens_mistral': 549, 'n_tokens_neox': 530, 'n_words': 200}