I've done this before, but it was a long trial and error process that resulted with my test machine having multiple copies of php, oci8, and the instant client, and I'm still not sure what it was that I did that made it work.
So far, i've set up yum
to use the remi repository, done yum install php php-oci8 php-pdo
, and downloaded the oracle instant client and done rpm -Uh oracle-instantclient11.2-basic-11.2.0.2.0.x86_64\ \(1\).rpm
When I do phpinfo()
on a page though, it still doesn't list oci8 as one of the modules.
I think the error is with the ORACLE_HOME
environment variable, but I'm not sure what it's supposed to be set to. right now i have:
SetEnv LD_LIBRARY_PATH /usr/lib/oracle/11.2/client64/lib
SetEnv ORACLE_HOME /usr/lib/oracle/11.2
in /etc/httpd/conf/httpd.conf
The last time I got this working I think I just kept on uninstalling php and php-oci8 and re-installing until things worked.
My working server has ORACLE_HOME set like this:
But the new non working one has ORACLE_HOME set here:
how do i set the ORACLE_HOME that is in the Enviroment
section of phpinfo()?