Install Oracle extension for PHP under CentOS, centosoracle_PHP tutorial

WBOY
Release: 2016-07-13 10:06:35
Original
901 people have browsed it

Install Oracle extension for PHP under CentOS, centosoracle

Environment

System: CentOS 6
PHP: 5.3.28

Download Oracle client

32-bit system

64-bit system

Copy code The code is as follows:

oracle-instantclient-sqlplus-10.2.0.4-1.x86_64.rpm
oracle-instantclient-jdbc-10.2.0.4-1.x86_64.rpm
oracle-instantclient-devel-10.2.0.4-1.x86_64.rpm
oracle-instantclient-basic-10.2.0.4-1.x86_64.rpm

Execute installation:

Copy code The code is as follows:

# rpm -ivh *.rpm

Download Oracle’s PHP extension

Official Download

Copy code The code is as follows:

wget http://pecl.php.net/get/oci8-2.0.7.tgz
# tar zxvf oci8-2.0.7.tgz
# cd oci8-2.0.7
# /usr/local/php/bin/phpize
# ./configure --with-php-config=/usr/local/php/bin/php-config --with-oci8=shared,instantclient,/usr/lib/oracle/10.2.0.4/client64/lib/
# make && make install

Change php.ini
Copy code The code is as follows:

# vi /usr/local/php/etc/php.ini

Add extension = "oci8.so"

Restart PHP

Copy code The code is as follows:

ps aux | grep php | grep root
kill -USER2 php_root_pid

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/958721.htmlTechArticlePHP installation Oracle extension under CentOS, centosoracle environment System: CentOS 6 PHP: 5.3.28 Download Oracle client 32-bit The system 64-bit system copy code is as follows: oracle-instantclient-sql...
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!