469,573 Members | 1,415 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,573 developers. It's quick & easy.

configure PHP with IBM-DB2

Hi All,

I am trying to configure php with IBM-DB2 and I get the following
error:

checking for IBM DB2 support... no
configure: error:
build test failed. Please check the config.log for details.
You need to source your DB2 environment before running PHP configure:
# . $IBM_DB2/db2profile

The command I use to configure is # ./configure
--with-mysql=/srv/mysql/mysql-standard-5.0.24a-linux-i686-glibc23
--with-apxs2=/srv/apache-2058/apache/bin/apxs
--with-ibm-db2=/opt/IBM/db2/V8.1
--with-pdo-odbc=ibm-db2,/home/db2inst1/sqllib

What am I doing wrong here?

Thanks,

Brent

Sep 21 '06 #1
7 7516
Brent Halsey wrote:
Hi All,

I am trying to configure php with IBM-DB2 and I get the following
error:

checking for IBM DB2 support... no
configure: error:
build test failed. Please check the config.log for details.
You need to source your DB2 environment before running PHP configure:
# . $IBM_DB2/db2profile

The command I use to configure is # ./configure
--with-mysql=/srv/mysql/mysql-standard-5.0.24a-linux-i686-glibc23
--with-apxs2=/srv/apache-2058/apache/bin/apxs
--with-ibm-db2=/opt/IBM/db2/V8.1
--with-pdo-odbc=ibm-db2,/home/db2inst1/sqllib

What am I doing wrong here?
First, you should make sure not to use the PHP ODBC driver. That driver has
a whole bunch of problems. There is a specific DB2 driver that fares much
better. Make sure that you use it.

Next, have you sourced the /home/db2inst1/sqllib/db2profile before running
the configure?

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Sep 21 '06 #2
Perhaps this is part of my problem, what is meant by 'source' the
/home/db2inst1/sqllib/db2profile ?
Knut Stolze wrote:
Next, have you sourced the /home/db2inst1/sqllib/db2profile before running
the configure?
Sep 21 '06 #3
Brent Halsey wrote:
Perhaps this is part of my problem, what is meant by 'source' the
/home/db2inst1/sqllib/db2profile ?
Run this:

$ source /home/db2inst1/sqllib/db2profile

or

$ . /home/db2inst1/sqllib/db2profile

Note the dot '.' in front of the filename.

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Sep 21 '06 #4
I ran source /home/db2inst1/sqllib/db2profile and then tried to
conifgure again and it appears to be working, my box is pretty slow.
I'll try to do the make and make install and let you know how it goes.
What needs to be done to the php.ini file?
Thanks!

Sep 21 '06 #5
The php.ini file should have the following contents added after the
make install:

extension=ibm_db2.so
Brent Halsey wrote:
I ran source /home/db2inst1/sqllib/db2profile and then tried to
conifgure again and it appears to be working, my box is pretty slow.
I'll try to do the make and make install and let you know how it goes.
What needs to be done to the php.ini file?
Thanks!
Sep 21 '06 #6
Thank you for all of your help. Everything is working now =) Cheers!

Sep 21 '06 #7
Ian
Brent Halsey wrote:
Hi All,

I am trying to configure php with IBM-DB2 and I get the following
error:

checking for IBM DB2 support... no
configure: error:
build test failed. Please check the config.log for details.
You need to source your DB2 environment before running PHP configure:
# . $IBM_DB2/db2profile

The command I use to configure is # ./configure
--with-mysql=/srv/mysql/mysql-standard-5.0.24a-linux-i686-glibc23
--with-apxs2=/srv/apache-2058/apache/bin/apxs
--with-ibm-db2=/opt/IBM/db2/V8.1
--with-pdo-odbc=ibm-db2,/home/db2inst1/sqllib
FYI, you probably want to use the ibm_db2 PECL module instead of the
bundled module -- it's written by IBM and doesn't use the unified ODBC
drivers.

Plus it's a lot easier to install it using pear.

http://pecl.php.net/package/ibm_db2/

Sep 21 '06 #8

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Christopher De Vries | last post: by
23 posts views Thread by Arapahoe | last post: by
reply views Thread by Markus Wollny | last post: by
reply views Thread by Samuel M. Smith | last post: by
1 post views Thread by Markus Wollny | last post: by
14 posts views Thread by david | last post: by
reply views Thread by Satish S Nandihalli | last post: by
1 post views Thread by Jim McCullars | last post: by
7 posts views Thread by Mathieu Prevot | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.