-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Librdkafka fails to create thread on RHEL 8 #2681
Comments
I believe the error code is irrelevant ("No such file or directory") since the glibc thrd_create() does not set errno, looking at the manual page it seems the only failure it can return is thrd_nomem, which indicates that the current process has a too strict thread, memory or stack limit. |
Todo: fix error string |
cat /proc/sys/kernel/threads-max30015 |
I noticed the same error message on Fedora 31 with librdkafka (0.11.6) from Fedora RPM repository (probably built without c11 thread support). In my case, an application is loading a plugin, which depends on librdkafka, using dlopen(). I discovered that the problem is caused by linker and multiple definitions of However, when the plugin is later loaded (by I resolved this issue by RTLD_DEEPBIND flag of dlopen(). Nevertheless, I think the library should not redefine these common symbols. |
Thanks for the root cause of this issue, @Lukas955 |
Description
Back Trace
#0 0x00007ffff7833340 in thrd_create () from /usr/lib64/libpthread.so.0
#1 0x00007ffff2193afe in rd_kafka_new (type=RD_KAFKA_CONSUMER, app_conf=0x894840, errstr=0x88c438 "",
errstr_size=512) at rdkafka.c:2179
[New Thread 0x7ffff0ca3700 (LWP 31923)]
rd_kafka_new (type=RD_KAFKA_CONSUMER, app_conf=0x894840, errstr=0x88c438 "", errstr_size=512) at rdkafka.c:2181
2181 rk->rk_init_wait_cnt--;
(gdb) n
2182 ret_err = RD_KAFKA_RESP_ERR__CRIT_SYS_RESOURCE;
(gdb) n
2183 ret_errno = errno;
(gdb) n
2184 if (errstr)
(gdb) n
2185 rd_snprintf(errstr, errstr_size,
(gdb) n
2188 rd_kafka_wrunlock(rk);
(gdb) p errstr
$1 = 0x88c438 "Failed to create thread: No such file or directory (2)"
(gdb)
Librdkafka is built with the following options
./configure --enable-gssapi --enable-ssl --disable-optimization
.........................
.........................
checking for libpthread (by pkg-config)... failed
checking for libpthread (by compile)... ok (cached)
checking for c11threads (by pkg-config)... failed
checking for c11threads (by compile)... failed (disable)
..................................
..................................
Checklist
IMPORTANT: We will close issues where the checklist has not been completed.
Please provide the following information:
<latest>
<RHEL 8>
The text was updated successfully, but these errors were encountered: