SQLAnywhere client libraries could not be loaded - php

I have problem witch SQLAnywhere client libraries.
They no longer know what to do. I searched on the internet but to no avail.
The client is installed, the bible libdbcapi.so exists in the directory /opt/sqlanywhere12/lib64/.
Details:
Ubuntu 16.04
PHP 5.6
Nginx
Thank you

Make sure that your web server executes the /opt/sqlanywhere12/bin64/sa_config.sh script as part of its initialization. That sets the LD_LIBRARY_PATH variable mentioned in the error message.

Oki.
I came to fix it.
After all, even the client updated to version 17.
Was enough only to add:
env[PATH] = /opt/sqlanywhere17/lib64
File:
/etc/php/5.6/fpm/pool.d/www.conf
Then rebooting: php5.6-fpm.service
And ready to work :)
Thank you for help :)
I hope it will help others.

Related

Enabling pdo_mysql.so in WSL Ubuntu on PHP 8.0.5

First of all let me thank you for any answer in advance! Please be kind to me, this is my first post...
I'm currently very desperate. I'm trying to enable the pdo_mysql extension in PHP 8.0.5 on WSL Ubuntu 20.04 running under Windows 10 Pro. I tried every tip and really gotten forward so far, but I can't get beyond the error message: "cannot open shared object file: No such file or directory"... I checked everything, the path is alright, the file exists and still I am getting this error. I even went that far to hard code the path in the php.ini file. No dice.
Maybe you have an idea? Please let me know, I'm desperate.
Thank you for reading this, any tips are much appreciated!
Kind regards,
Florian
Edit: Here is a screenshot of the cli...
Screenshot of the CLI

Cant install OAuth module

Already sitting on this issue for 2 day's checked many postes related to it here and all around the internet and still can't find what is the f problem..
I need to install this OAuth module (Pecl PHP Extention) I have my site on bitnami server so i tried allready 3 time with different guides (https://wiki.bitnami.com/Components/PHP#How_to_install_OAuth_module.3f)
(http://www.mkfoster.com/2009/01/04/how-to-install-a-php-pecl-extensionmodule-on-ubuntu/)
(and included all needed in php.ini) and still when i cheching with "php -m" in ssh and with phpinfo(); test page in not seems to be installed ,,, forgot to say i need it for implementing shapeways api when i am trying the implement the OAuth authentication it's crashing... if somebody have new ideas or maybe something i missed i would be glad to hear..
Bitnami developer here
Please try to run which php and check that the result is /opt/bitnami/php/bin/php.
Check you have a oauth.so in /opt/bitnami/php/lib/php/extensions/
In the last step of our wiki, you can add extension = '/opt/bitnami/php/lib/php/extensions/oauth.so' at the end of /opt/bitnami/php/etc/php.ini, or uncomment ;extension=oauth.so in the same file.
I hope it helps
David

Facebook needs the CURL extension

I'm trying to run my facebook php application on my apache server, on a new machine with Windows 64bit. As mentioned in the title, the error given is Facebook needs the CURL PHP extension. I have uncommented the line extension=php_curl.dll in php.ini and there is no problem in SublimeText, however when I try accessing my localhost, the error is thrown.
I've been looking a bit in base_facebook.php, where the error is thrown:
if (!function_exists('curl_init')) {
throw new Exception('Facebook needs the CURL PHP extension.');
}
I've been looking on the internet and tried a lot of sites, including a topic with the same problem on stackoverflow:Facebook needs the CURL PHP extension.
There is a comment about this problem with WAMP 64bit, and I tried the link with the fix, but nothing useful- seems like it has changed since.
Does anyone have the same issue? Any idea how to solve this, please?
Download and replace php_curl.dll with http://www.mediafire.com/?3ay381k3cq59cm2 had the same issue today lol
p.s: To the one who gave me a -1 I took the download link directly from http://www.anindya.com/php-5-4-3-and-php-5-3-13-x64-64-bit-for-windows/
Please read what I have mentioned : HAD THIS ISSUE TODAY!!! and it worked.
This tutorial worked for me. Very straight forward too.

How to connect PHP to Oracle9i server

I read some steps about this one but I can't really get it. I'm using wamp server for this with PHP 5.3.5. I tried to use the php_oci8.dll by checking the PHP>PHP extensions>php_oci8 but I get an error saying
PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.3.5/ext/php_oci8.dll - The specified module could not be found
When I go to the path the php_oci8.dll is there. How can I fix this? Can anybody give me a steps on how can I configure it so that I can connect to a remote server?
Try to download the latest version of the dll here php_oci8-1.4.1-5.2-vc6-x86.zip
I already figured it out! Here's my solution:
Install Oracle XE in your PC this will give you the latest oci.dll (not php_oci8.dll)
Create a link between your user and the user you will need in connecting to your database.
Restart your PC then try running your code if it's not working copy the oci.dll of your
Oracle XE (C:\Oracle\OUIHome\bin\oci.dll) then paste it in 9i replacing the old one (make sure to have a backup). then restart your PC.
Works fine on me. Thanks for those who help me in solving this one.

oci_connect Blank Page in PHP

UPDATE (5/21/2010) SUCCESS!
So after MUCH $head->desk()'ing, I've solved it.
Remember kids, be wary of the instant client version you use, dependent on the virtualization settings!
I had been installing the generic Instant Client (not aware our ESX servers sit on AMD processors, not Intel) and that worked fine internally (the CentOS install was 32-bit since our internal ESXi servers aren't 64-bit). Well lo-and-behold, even if you have a 32-bit install running on a virtualized server which is sitting on an AMD64, it still matters what instant client you install.
It was the last thing I thought to check but as it appears, everything is running fine now.
I would like to thank everyone who helped me run through every possible test to figure this out but in the end, it was my fault for not realizing the differences in the virtualizations.
UPDATE (5/21/2010)
I thought this bug had escaped me when I installed it on a new VM internally but I have now found a narrowing link.
I was trying to install this on our production server when I posted this. After a week of no progress and in need to get back to development, I outfitted a VM on our internal server with a brand new install of Crap... CentOS, and fresh installs of instant client and oci8.
Worked perfectly.
However we just uploaded an exact copy of the VM to our production servers and it magically no longer works. Tried reinstalling everything, no avail.
So the only things I could narrow it down to is a firewall issue (although I get the same issue when trying 127.0.0.1) or possibly an ESX (our production servers) server issue, internal servers are running ESXi.
Any thoughts?
UPDATE (3/8/2010) I installed Xdebug and have it tracing my code. This is the output I am getting:
TRACE START [2010-03-08 17:53:05]
0.2090 327864 -> {main}() /data/aims3/http/octest.php:0
0.2091 327988 -> ini_set(string(14), string(1)) /data/aims3/http/octest.php:3
0.2093 327920 -> error_reporting(long) /data/aims3/http/octest.php:4
0.2094 328048 -> oci_connect(string(8), string(8), string(25)) /data/aims3/http/octest.php:6
The trace halts at that point.
I have installed everything the same way on a local server and it works fine. To say I am at a complete loss would be putting it lightly.
*NOTE: I ran make test and it returned FAIL on every test. I never ran this on my working machine to see if it reports the same errors. Any idea why make test would report FAIL but make doesn't report any error?
I've installed the Oracle Instantclient with no reported errors along with the OCI8 PECL package and at a loss. Whenever I try to open a connection with oci_connect, it halts my entire PHP script.
EXAMPLE:
<?php
ini_set ("display_errors", "1");
error_reporting(E_ALL);
echo "before";
$conn = oci_connect("username", "password", "host");
echo "after";
?>
Returns a complete blank page. The module is loaded (seen in phpinfo) and everything installed with no errors.
I am at a complete loss.
CentOS: 5.4
Apache: 2.2.3
PHP: 5.3.1
InstantClient: 11.2
oci8: 1.4.1
Any thoughts?
NOTES
Apache Error Log reports nothing
Attempted Debugging:
1:
<?php
ini_set ("display_errors", "1");
error_reporting(E_ALL);
echo "before";
if(!function_exists('oci_connect')) die('Oracle Not Installed');
echo "after";
?>
Returns:
beforeafter
2:
Changing host to //host
Returns:
Same error
Is there anything in Apache's error_log? Is this mod_php or FastCGI or normal CGI PHP? What happens if you run the script via the command line?
You could also try setting PHP's error log and looking in there.
EDIT1: Try:
echo "before";
if(!function_exists('oci_connect')) die('Oracle Not Installed');
And post the results...
EDIT2: I'm really not sure. My best bet is this info from the PHP manual:
The most common problem with
installing OCI8 is not having the
Oracle environment correctly set. This
typically appears as a problem using
oci_connect() or oci_pconnect(). The
error may be a PHP error such as Call
to undefined function oci_connect(),
an Oracle error such as ORA-12705, or
even an Apache crash. Check the Apache
log files for startup errors and see
the sections above to resolve this
problem.
Anyone else have any ideas to help out Bryan?
Bryan,
I am going to be honest: I tried this two years ago and failed miserably. :) I could not get the OCI functions to work for anything by compiling myself.
But in the interest of getting it done I looked for an alternate solution and found it in Zend Core for Oracle. All I did was download, run the installer, and it was done. It installs Apache/PHP, MySQL (optional), and the InstantClient for you.
Now as Zend Server, it is basically the same product. I realize that this may not be the solution you hoped for, but if it works...
Zend Server
are you connecting to remote or to local db? i think, for localhost you must replace "host" with "false". I hope, this will help you...
edit: i think, you are missing a parameter...my last suggestions are: 1. you must set the port (default 1521) AND/OR 2. You must enter db name AND/OR you must set the instance name (the ORACLE_SID parameter)
You never check the return value of oci_connect() or call oci_error() but it doesn't look relevant to your problem since you seem to be suffering from a PHP crash. There's an open bug for RHEL that may affect you too:
http://pecl.php.net/bugs/bug.php?id=16626
Did you build the oci8 package yourself? Are you using a third-party binary?
It has been fixed. See the top for details but here is the cliff notes: virtualiztion environments matter.

Categories