oracle注入环境搭建:CentOS7 lnmp安装oci8扩展连接oracle

https://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html
1.安装依赖

rpm -ivh oracle-instantclient18.5-basic-18.5.0.0.0-3.x86_64.rpm
rpm -ivh oracle-instantclient18.5-devel-18.5.0.0.0-3.x86_64.rpm
rpm -ivh oracle-instantclient18.5-jdbc-18.5.0.0.0-3.x86_64.rpm
rpm -ivh oracle-instantclient18.5-sqlplus-18.5.0.0.0-3.x86_64.rpm
tar zxvf oci8-2.2.0.tgz
cd oci8-2.2.0
phpize
./configure --with-oci8=shared,instantclient,/usr/lib/oracle/18.5/client64/lib --with-php-config=/usr/local/php/bin/php-config
make && make install

2.修改php.ini配置 /usr/local/php/etc/php.ini,添加

extension=oci8.so

3.重启lnmp

lnmp restart

相关下载(下载最新版):
http://pecl.php.net/package/oci8
https://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html