Install
Fluent Bit’s official documentation provides up-to-date installation guides for different operating systems. Open this link and select your OS. Simply follow the steps in the relevant installation manual.Configure
The Fluent Bit configuration file consists of two sections:INPUT and OUTPUT. INPUT determines the log source, and OUTPUT sets the destination. To set up the configuration file:
- Open the
fluent-bit.conffile and add the following data:
tail: Data source type/var/log/syslog: File path to monitorlaas-example.gcore.com:443: Kafka endpoint — find this on the Managed Logging page in the Gcore Customer Portalyourlogin.yourtopic: Username from the Managed Logging page and topic name, separated by a dot (.)yourlogin: Username from the Managed Logging pageyourpassword: Password from the Managed Logging page
INPUT section accordingly.
Descriptions of the OUTPUT parameters
Descriptions of the OUTPUT parameters
- [OUTPUT]: Type of process (export).
- name: Servers where logs will be delivered (Kafka servers).
- brokers: Server(s) where logs will be exported.
- topics: Topic(s) where logs will be exported.
- rdkafka.security.protocol: Security protocol that encrypts data in transit.
- rdkafka.sasl.mechanism: Authentication mechanism used to verify the username and password for the logs storage.
- rdkafka.sasl.username: Username used to verify the sender.
- rdkafka.sasl.password: Password used to verify the sender.
-
Save the changes in the
fluent-bit.conffile. - Restart Fluent Bit, and it will begin sending logs to the Gcore Managed Logging.
No timestamps
Some services (for example, nginx) transmit timestamps of logs in a non-standard format. In this case, OpenSearch Dashboards will show logs without their date and time. If this happens, add the following line inside the[OUTPUT] section. This instructs Fluent Bit to forward timestamps in ISO 8601 format, which is compatible with services like nginx.