Connect Fluentd to Bronto
Fluentd must be installed on the server hosting your logs to ensure efficient and reliable log transportation.
For detailed installation instructions check out the Fluentd documentation site.
Configurate FluentD
After installation, FluentD requires the output configuration to communicate with Bronto system.
Parameter | Value | Required | Description |
---|---|---|---|
source.@type | tail | Yes | Type of source plugin; here, it follows file contents and collects logs. |
source.path | /path/to/your/logs | Yes | Path to the log files to be tailed. |
source.tag | <OPTIONAL_LOG_TAG> | No | Optional tag for the log entry. |
source.refresh_interval | 5s | No | Interval for refreshing the file list to check for new logs. |
source.parse | { "@type": "json" } | Yes | Specifies the parser type, here JSON format |
source.pos_file | /var/log/td-agent/buffer/fluentd.pos | Yes | Position file to remember where it last read |
filter.@type | record_transformer | Yes | Type of filter plugin to transform the log records |
filter.record | { "hostname": "#{Socket.gethostname}" } | Yes | Transformation record to add the hostname to the log entry |
match.@type | http | Yes | Type of output plugin; here, to send logs via HTTP |
match.endpoint | https://ingestion.<REGION>.bronto.io:443 | Yes | HTTP endpoint to send the log data |
match.http_method | post | Yes | HTTP method to use when sending data |
match.buffer.@type | file | Yes | Configuration for buffering before sending. |
match.path | "/var/log/td-agent/buffer/http" | Yes | Configuration for buffering before sending |
match.chunk_limit_size | 5mb | Yes | Configuration for buffering before sending logs |
match.flush_interval | 10s | No | Interval for flushing data from the buffer |
match.chunk_limit_size | 5MB | No | Maximum size of a data chunk before it’s flushed |
match.overflow_action | block | No | Action to take when the buffer queue is full |
match.format | { "@type": "json" } | Yes | Specifies the format of data when being sent, here JSON format |
match.headers | {"x-bronto-api-key": "<YOUR_API_KEY>", "x-bronto-service-name": "<YOUR_SERVICE_NAME>", "x-bronto-service-namespace": "<YOUR_SERVICE_NAMESPACE>"} | Yes | Headers to be sent along with HTTP requests |
The table below lists the parameters used to determine the Bronto dataset associated with the ingested data, ordered from highest to lowest precedence.
Parameter Name | Parameter Type |
---|---|
x-bronto-service-name | HTTP Header |
x-bronto-log-name | HTTP Header |
kubernetes.annotations.logs.bronto.io/dataset | Log Metadata |
service.name | Log Metadata |
service_name | Log Metadata |
kubernetes.annotations.service_name | Log Metadata |
kubernetes.labels.app.kubernetes.io/name | Log Metadata |
kubernetes.container_name | Log Metadata |
The table below lists the parameters used to determine the Bronto collection associated with the ingested data, ordered from highest to lowest precedence.
Parameter Name | Parameter Type |
---|---|
x-bronto-service-namespace | HTTP Header |
x-bronto-logset | HTTP Header |
kubernetes.annotations.logs.bronto.io/collection | Log Metadata |
service.namespace | Log Metadata |
service_namespace | Log Metadata |
Finally the table below lists the parameters used to assign tags to datasets, ordered from highest to lowest precedence.
Parameter Name | Parameter Type | Example |
---|---|---|
x-bronto-tags | HTTP Header | x-bronto-tags: tag1=value1,tag2=value2,… |
kubernetes.annotations.tags.logs.bronto.io/<TAG_NAME> | Log Metadata | kubernetes.annotations.tags.logs.bronto.io/tag1: value1 |
Verify Log Collection
Once you have applied your configuration and restarted Fluent Bit, you can expect to see your log data being ingested to Bronto and accessible via the Search page.