I don't have a oracle database installed in my system. But i want to connect to the remote system. Do i just need to install oci8 extension library or i need to install both instantclient and the oci8 extension?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
If I remember correctly, OCI8 extension wouldn't even compile without Instant Client; if you install using PECL, it asks you for Instant Client path. Moreover, from my experience, you'll also need Instant Client SDK in addition to Basic, unpack them to one directory, and make some symlinks before running PECL command:
sudo ln -s libclntsh.so.* libclntsh.so
sudo ln -s libocci.so.* libocci.so
Don't forget to enable the config later:
echo "; configuration for php oci8 module" | sudo tee /etc/php5/conf.d/oci8.ini
echo extension=oci8.so | sudo tee -a /etc/php5/conf.d/oci8.ini
Taken from this post (in Russian), also installed OCI8 myself recently on Debian 7.