ibmdb/python-ibmdb

Error while running ibm_db on python:3-slim-bookworm docker image.

rmohan17 opened this issue · 2 comments

  • Operating System Name:

  • db2level output from clidriver if in use:

  • Target Db2 Server Version:

  • Python Version:

  • ibm_db version:

  • For non-Windows, output of below commands:
    uname
    uname -m

  • Value of below environment variables if set:
    IBM_DB_HOME:
    PATH:
    LIB/LD_LIBRARY_PATH/DYLD_LIBRARY_PATH:

  • Test script to reproduce the problem.

  • For installation related issue, complete output of pip install ibm_db command.

Steps to Reproduce:

-- We have installed ibm_db on python:3-slim-bookworm docker image but while running this docker image on Docker Desktop install on Mac M1, we are getting below error, Please advise

rmohan30@LAMU0R3DQJV9PMT eems-utils-py % docker run eems-utils-py
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Traceback (most recent call last):
File "//Scheduler.py", line 8, in
from src.odm.odm_proc_stats_cnt import __fetch_proc_stats_cnt
File "/src/odm/odm_proc_stats_cnt.py", line 1, in
import ibm_db
ImportError: /usr/local/lib/python3.12/site-packages/ibm_db.cpython-312-x86_64-linux-gnu.so: undefined symbol: PyUnicode_FromUnicode

we are getting

@rmohan17
Currently ibm_db doesn't support python 3.12,
Please use python 3.11
Please refer below link to install ibm_db on MacOS M1/M2 chip system.
https://github.com/ibmdb/python-ibmdb/blob/master/INSTALL.md#-7-ibm_db-installation-on-macos-m1m2-chip-system-arm64-architecture

Check #890