Skip to content

Latest commit

 

History

History
47 lines (31 loc) · 2.6 KB

File metadata and controls

47 lines (31 loc) · 2.6 KB

Configure Fluent Bit

Fluent Bit uses configuration files to store information about your specified inputs, outputs, filters, and more. You can write these configuration files in one of these formats:

Unit sizes

Some configuration settings in Fluent Bit use standardized unit sizes to define data and storage limits. For example, the buffer_chunk_size and buffer_max_size parameters for the Tail input plugin use unit sizes.

The following table describes the unit sizes you can use and what they mean.

Suffix Description Example
none Bytes: If you specify an integer without a unit size, Fluent Bit interprets that value as a bytes representation. 32000 means 32,000 bytes.
k, kb, K, KB Kilobytes: A unit of memory equal to 1,000 bytes. 32k means 32,000 bytes.
m, mb, M, MB Megabytes: A unit of memory equal to 1,000,000 bytes. 32m means 32,000,000 bytes.
g, gb, G, GB Gigabytes: A unit of memory equal to 1,000,000,000 bytes. 32g means 32,000,000,000 bytes.

Command line interface

Fluent Bit exposes most of its configuration features through the command line interface. Use the -h or --help flag to see a list of available options.

# Podman container tooling.
podman run -rm -ti fluent/fluent-bit --help

# Docker container tooling.
docker run --rm -it fluent/fluent-bit --help

Validate configuration with --dry-run

Use the --dry-run flag to validate a configuration file without starting Fluent Bit:

fluent-bit --dry-run -c /path/to/fluent-bit.yaml

A successful validation prints configuration test is successful and exits with code 0. If validation fails, Fluent Bit exits with a non-zero code and prints the errors to stderr.

As of Fluent Bit 4.2, --dry-run performs full property validation in addition to syntax checking. Prior to 4.2, unknown or misspelled plugin property names would only surface as errors at runtime; --dry-run now catches them during validation. For example, a configuration with an unknown property on a dummy input produces:

[error] [config] dummy: unknown configuration property 'invalid_property_that_does_not_exist'.