0

I am having difficulty installing the ibm_db package for Python 3.4 on a 32 bit windows virtual server. I have tried easy_install, pip, and installing the pacakge manually. When I used pip install I am able to reference the package with import ibm_db, but I am not able to use it without getting the following error:

Traceback (most recent call last):
 File "C:/Python34/Lib/site-packages/ibm_db-2.0.6-py3.4.egg/ibm_db.py", line 10, in <module>
   __bootstrap__()
 File "C:/Python34/Lib/site-packages/ibm_db-2.0.6-py3.4.egg/ibm_db.py", line 9, in __bootstrap__
   imp.load_dynamic(__name__,__file__)
ImportError: DLL load failed: The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail.

When I use easy_install I am unable to reference the library using import ibm_db. I was wondering if there was a simple solution to this.

3 Answers 3

0

How to make ibm_db work on MAC

Make sure that you has IBM DB2 EXPRESS 2 installed on your machine: https://www.ibm.com/analytics/us/en/db2/trials/?S_CMP=ECDDWW01&S_TACT=ACDB201

To install the DB2 EXPRESS 2 extact the files into your computer and:

cd ~/Downloads/expc ; sudo ./db2_install

Make sure that you has your $HOSTNAME variable properly configured:

echo "127.0.0.1 $HOSTNAME" >>/etc/hosts

Create another user using mac gui (System Preferences -> Users & Groups). Use Standard (Non-Admin) privileges.

Create the instance with these commands:

cd /opt/IBM/db2/V10.1/instance ; sudo ./db2icrt -u <newuser> <newuser>

Export the following variables

$ sudo -s
$ export IBM_DB_LIB=/Users/<newuser>/sqllib/lib64
$ export IBM_DB_DIR=/Users/<newuser>/sqllib
$ export ARCHFLAGS="-arch x86_64"

Intall ibm_db

pip3 install ibm_db
0

Try easy_install ibm_db, it worked for me on both Linux and Windows.

-1

Similar problem has been addressed here: https://groups.google.com/forum/#!topic/ibm_db/-HaQ48BhcfQ

Please check if that helps!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.