duckdb: centos 7 (multiple libs) not found
What does happen?
Tried to run the compiled linux duckdb binary. seeing messages like version GLIBC_2.23โ not found (required by ./duckdb)`.
What should happen?
Assumed it would run.
To Reproduce Steps to reproduce the behavior. Bonus points if those are only SQL queries.
- Download latest binary cli for linux
- Run.
Environment (please complete the following information):
- CentOS Linux release 7.9.2009 (Core)
- DuckDB Version 0.2.5
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 19 (7 by maintainers)
@darked89 its an interesting option to get out of this glibc hell @Mytherin @samansmink lets discuss
Iโm revamping this closed issue since the same error happens on AWS Lambda (even with a custom Dockerfile with their image).
Error: /lib64/libm.so.6: versionGLIBC_2.29 not found`Amazon Linux 2 is running glibc 2.26.
Any help?
Docker image used:
While precompiled (with musl?) single duckDB executable would be a desired solution, maybe there can be some stop gap hack: https://stackoverflow.com/questions/847179/multiple-glibc-libraries-on-a-single-host
meaning:
I assume that going back in time and trying to modify duckdb code to be compatible with ancient P, Q, R versions of glibc possible to encounter in the wild is more costly than compile some new version of glibc. But frankly I have not checked it.
I would also suggest putting duckDB image on DockerHub. Most of the HPCs should have Singularity installed, so this is another way to run it.
Hope it helps,
Darek Kedra
Note that this seems to be the case with Red Hat line of distributions. Looks like they tend to keep the same glibc across minor versions.
RHEL release dates
RHEL 8.0 released on 2019-05-07 has glibc-2.28-42.el8.x86_64.rpm
RHEL 8.6 released on 2022-05-10 has glibc-2.28-189.1.el8.x86_64.rpm
RHEL 9.0 released on 2022-05-17 has glibc-2.34-28.el9_0.x86_64.rpm
Apparently, duckdb requires at least glibc 2.29:
Given how recent RHEL 9.0 is and how risk-averse / slow many places are with regards to upgrades, itโs safe to assume stock duckdb build will not be usable for people on RHEL (and probably derivatives) for a very long time. At which time, it will probably stop working because a newer glibc will be released. ๐
So hopefully a musl build is an option. Or perhaps having another build with an older glibc.
Hello,
No idea if this is a viable option, but at least few command line utils written in Rust (ripgrep, choose, bat) provide executables linked to musl library.
Since old Centos can be found on at least a handful of HPC clusters at times with extra restrictions compiling programs can be problematic.
Best,
DK
@hannesmuehleisen
Can confirm that it successfully compiled and ran.