fluent / fluent/fluent-bit

kafka output crashes fluent-bit 4.0.8 uncleanly if cert file doesn't exist

Open
#10,872 4 comments 1 reaction 1 assignee Claimed by @edsiper View on GitHub
status: waiting-for-triage
Dominant language
C
Stars
8.1k
Forks
2k
Avg merge
4d 16h
Merged PRs (30d)
58

Description

## Bug Report

```
#0 0x0000ffff8a6bf9b4 in __pthread_kill_implementation () from /lib64/libc.so.6
#1 0x0000ffff8a6763a0 in raise () from /lib64/libc.so.6
#2 0x0000ffff8a662264 in abort () from /lib64/libc.so.6
#3 0x0000aaaab6e547a8 in flb_signal_handler ()
#4
#5 0x0000aaaab6f63830 in flb_kafka_topic_destroy_all ()
#6 0x0000aaaab6f638d0 in flb_out_kafka_destroy ()
#7 0x0000aaaab6f68218 in flb_out_kafka_create ()
#8 0x0000aaaab6f684b8 in cb_kafka_init.lto_priv ()
#9 0x0000aaaab6e6e90c in flb_output_init_all ()
#10 0x0000aaaab6e860a4 in flb_engine_start ()
#11 0x0000aaaab6e5b238 in flb_lib_worker ()
#12 0x0000ffff8a6bdd78 in start_thread () from /lib64/libc.so.6
#13 0x0000ffff8a72addc in thread_start () from /lib64/libc.so.6
```

```
[output:kafka:kafka.2] warpstream_proxy_target=proxy-produce#producer-1: [thrd:app]: error:80000002:system library::No such file or directory: calling fopen(/path/to/cert.pem, r)
[output:kafka:kafka.2] warpstream_proxy_target=proxy-produce#producer-1: [thrd:app]: error:10080002:BIO routines::system lib
[output:kafka:kafka.2] failed to create producer: ssl.certificate.location failed: error:0A080002:SSL routines::system lib
```

Steps to reproduce the problem:

Configure the kafka output with a TLS cert that doesn't exist on the filesystem, and start fluent-bit.

**Expected behavior**
Fluent-bit exits cleanly with error (to be restarted by kube/systemd) and without coredumping.

**Your Environment**

* Version used: 4.0.8
* Configuration:
* Environment name and version (e.g. Kubernetes? What version?):
* Server type and version:
* Operating System and version: Linux 6.1.147.amzn2023.aarch64 #1 SMP Sat Aug 9 00:25:55 UTC 2025 aarch64 aarch64 aarch64 GNU/Linux

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.