1

I am trying to connect to IBM iSeries using pyodbc, a Python interface for ODBC, on Linux Red Hat (Intel 64bit arch).

The following is what I have done:

  1. Installed gcc-c++ (needed to compile pyodbc), unixODBC, unixODBC-devel

  2. Installed iSeriesAccess-6.1.0-1.0.x86_64.rpm:

sudo rpm -ivh http://ftpmirror.your.org/pub/misc/ftp.software.ibm.com/as400/iSeriesAccess-6.1.0-1.0.x86_64.rpm --nodeps
  1. Attached the driver to unixODBC
odbcinst -i -d -f /opt/ibm/iSeriesAccess/unixodbcregistration64
  1. Since I had some issues with libraries, I symbolic linked them:
sudo ln -s /opt/ibm/iSeriesAccess/lib64/libcwb* /usr/lib/
  1. I configured the ODBC Data Source to access the AS400’s database: /etc/odbc.ini:
[AS400]
Description = Database iSeries
Driver = iSeries Access ODBC Driver
System = XXX.XXX.XXX.XXX
Port = 8471
UserID = XXXXXX
Password = XXXXXX
Naming = 1
Database = XXXXXXXXX
ConnectionType = 0
CommitMode = 2
BlockFetch = 1
BlockSizeKB = 512
  1. I tested the connection:
> isql -v AS400

+---------------------------------------+
| Connected!                            |
|                                       |
| sql-statement                         |
| help [tablename]                      |
| quit                                  |
|                                       |
+---------------------------------------+
SQL>

I was able to connect, but when running any SQL query I get Segmentation fault (core dumped).

By checking /var/log/messages I see this:

isql[5767]: segfault at 7f6fdb30020e ip 00007f6ed372ff71 sp 00007ffcce17d5f0 error 4 in libcwbcore.so[7f6ed369e000+11c000]

I would like to re-install a different driver (e.g iSeriesAccess-7.1.0-1.0x86_64.rpm), but I am not able to find it.

Fabio
  • 121
  • 5

1 Answers1

0

The tool is no longer called iSeries Access, but IBM i Access Client Solutions. Look here, and scroll down to the bottom of the page for Linux Application Package. But, the last line on the page says that the optional packages are only available through ESS. So you or your administrator will need to get that for you.

jmarkmurphy
  • 151
  • 4