I would lke to run DuckDB with the spatial extension, but I am running into glibc issues:
duckdb.load_extension("spatial")
gives:
duckdb.IOException: IO Error: Extension "/home/xxx/.duckdb/extensions/v0.8.1/linux_amd64/spatial.duckdb_extension" could not be loaded: /lib64/libm.so.6: version `GLIBC_2.23' not found (required by /home/xxx/.duckdb/extensions/v0.8.1/linux_amd64/spatial.duckdb_extension)
Compiling duckdb from source gives the same error.
ldd --version returns 2.17, and it cannot be updated using yum.
What would be the best way forward? Compile ldd myself and use that?
Cfr. https://bitsanddragons.wordpress.com/2018/04/11/importerror-lib64-libc-so-6-version-glibc_2-18-not-found-on-centos-7/
Comments
Can you please specify what…
Can you please specify what versions you are using (Python, DuckDB, etc.)?
If the default Python installation doesn't work for you, you can use conda to choose another Python version for your project.
I have no experience with DuckDB, but I tried to load it using Python 3.10 in a conda environment and it seems to work.
Creating conda environment: $ conda create -n duckdb python=3.10
Activate conda environment: $ conda activate duckdb
Installing duckdb in conda environment: $ pip install duckdb
Try to load spatial extension: $ python3 >>> import duckdb >>> duckdb.install_extension("spatial") >>> duckdb.load_extension("spatial") >>> duckdb.sql('FROM duckdb_extensions()').show()
The output of the last instruction confirms that the spatial extension is loaded.