[Stackoverflow] [Progress OpenEdge ABL] odbc_connect not working with FPM but works in CLI

Status
Not open for further replies.
B

Boris Cerati

Guest
I am trying to connect to a Progress database using PHP. For that I am using odbc_connect function, like this :

Code:
$conn_id = odbc_connect('Progress OpenEdge Wire Protocol', 'user', 'pass');

My webserver is using a Ubuntu 18.04 with php7.3-fpm and Nginx. It runs both php-fpm and nginx as www-data (by default). When a access my app with the browser (so it uses nginx/fpm) I get this error :

Warning: odbc_connect(): SQL error: [unixODBC][Driver Manager]Can't open lib '/opt/Progress/DataDirect/Connect64_for_ODBC_71/lib/ddoe27.so' : file not found, SQL state 01000 in SQLConnect

When I am executing the same code with the cli (and the www-data user) it is working. I have my env vars set properly in both cli and fpm (LD_LIBRARY_PATH, ODBCINI, ODBCINST).

Any idea ?

Continue reading...
 
Status
Not open for further replies.
Top