After following the install instructions for oracle instant client, php is not able to load the oci8 extension.
http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html#ic_x64_inst
I am getting an error.
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/oci8.so' - libmql1.so: cannot open shared object file: No such file or directory in Unknown on line 0
I have verified both oci8.so and libmql1.so locations.
Am I missing something?
I solved adding the following to
/etc/environment
:I followed this tutorial: https://gist.github.com/hewerthomn/81eea2935051eb2500941a9309bca703
What I did was completely remove any installations of PHP and reinstall the version that I need.
Source: https://askubuntu.com/a/59889/226518
I'm using Ubuntu 16.04 and php version 7.1
There are few directories in
/usr/lib/php/
for example20131226 for php5.6
20160303 for php7.1
so problem with me that, the oci8 extension got installed on the wrong ( a user lib folder for php7.2) so I had to remove the php 7.2 completly
sudo apt-get purge php7.2-common
then I had uninstall the oci8 by running following command
and install again by running the following command
To check the configuration loaded you do
And make sure that all extension are installed in the correct extension directory.
Make changes in the
/etc/php/7.1/apache2/php.ini
and/etc/php/7.1/cli/php.ini
Check by running
phpinfo();
You must see this, ignore the cli if that stills gives you same error as your web shows the extension is getting loaded.