Page 1 of 1

Configure PHP 4.3.4 with Redhat 7.2 and IBM-DB2

Posted: Tue Nov 18, 2003 2:23 pm
by jkpalmer52
I've installed Linux Redhat 7.2 as a server and would like to get IBM DB2 workgroup edition 8.1 to be able to be "recognized" by PHP.

All instructions that I've found indicate that I need to
1) Download and then do a tar zxf php-4.3.4.tar.gz
2) Run the ./configure --with-ibm-db2=/home/db2inst1/sqllib - etc.
3) Do a make
4) Do a make install

All of which I've done using PHP-4.3.4.tar.gz

I've also checked my Apache config settings per the instructions given but the install doesn't appear to be configured properly.

Has anyone been successful with Redhat 7.2, PHP-4.3.4 and IBM DB2 WGE 8.1? If so, would you please tell me how you did it!!!!!!

My problem is that when I run the phpinfo() function on my localhost, it still returns version 4.0.20, which was installed when I installed RH 7.2.

I've even gone so far as to eraseed the PHP that was installed with RH 7.2 with no positive results.

Has anyone been successful with Redhat 7.2, PHP-4.3.4 and IBM DB2 WGE 8.1? If so, would you please tell me how you did it!!!!!!


-jP

Posted: Tue Nov 18, 2003 2:34 pm
by d-m
I did that with 7.1 years ago .. and put the solution at odbc_connect at the http://www.php.net site.. probably its the same way ..

_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
odbc_connect ERRO at DB2
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/

To Solve the problem with DB2 + PHP folow this steps!

INSTALL THE PROGRAM LIKE THIS!

-- DB2 --
Install the DataBank
Install Application Tools
-- END DB2 --

--- APACHE ---
cd ../mod_ssl-2.8.5-1.3.22/
./configure --enable-module=so --with-apache=../apache_1.3.22/ --with-ssl=../openssl-0.9.6c/
cd ../apache_1.3.22/
make
make certificate TYPE=custom
make install
--- END APACHE ---

-- PHP --
cd ../php-4.1.1/
./configure --with-apxs=/usr/local/apache/bin/apxs --with-pgsql --with-mysql --with-ibm-db2=/usr/IBMdb2/V7.1
make
make install
-- END PHP ---

-- LIB --
vim /etc/ld.so.conf
add line: /usr/IBMdb2/V7.1/lib
execute: ldconfig
-- END LIB --

To Solve the error ODBC_CONNECT exec the db2profile at the apachectl!!! Like this!

-- APACHE EDIT TO RUN DB2 --
vim /usr/local/apache/bin/apachectl
add line: . /usr/home/db2inst1/sqllib/db2profile
-- END APACHE EDIT TO RUN DB2 --

NOW run /usr/local/apache/bin/apachectl startssl

DONE !!!!!

You have a DB2 + APACHE + SSL + PHP + MYSQL + POSTGRES .

Enjoy

Posted: Tue Nov 18, 2003 2:50 pm
by jkpalmer52
My problem seems to be that the version of Apache and PHP do not get "overridden" with the ./configure, make and make install, therefore leaving me with what RedHat 7.2 installs as default.

Posted: Tue Nov 18, 2003 2:59 pm
by d-m
jkpalmer52 wrote:My problem seems to be that the version of Apache and PHP do not get "overridden" with the ./configure, make and make install, therefore leaving me with what RedHat 7.2 installs as default.
Make sure U uninstall the apache.rpm download the sorces and compile.. if you aready compiled wronk do a : make distclean
than compile as the way I told before :)