1

I have a Linux redhat6 server, with apache+nginx servers. To get the data from remote Oracle db I compiled pdo_oci.so for my php 5.3 and it was working perfectly. There were a lot of troubles with configuring TCPS connection with wallet, but they were solved and were working.

But our server machine was rebooted from snapshot, which was made an hour earlier, and this connections fall down. I have checked sqlplus connections, to find out where is the main trouble, and it was not working either. I set up environment variables $ORACLE_HOME , $TNS_ADMIN and $LD_LIBRARY_PATH again, and sqlplus connection was restored. BUT not the pdo_oci connection. I am searching google for any info, but cannot remember the solution.

The error that I'm getting looks like this:

Failed to execute your db connection: SQLSTATE[HY000]: pdo_oci_handle_factory: ORA-28759: failure to open file (/usr/local/src/php-5.3.3/ext/pdo_oci/oci_driver.c:579)

Any help and variants are highly appreciated!

Altenrion
  • 764
  • 3
  • 14
  • 35
  • Have you [turned on tracing](http://stackoverflow.com/questions/32284692/oracle-instant-client-ora-28759-failure-to-open-file)? – timclutton Oct 14 '15 at 09:24
  • Does the file exist in that directory ? – frz3993 Oct 14 '15 at 09:29
  • Yes, but i have no valuable information. I turned on tracing of odbc connection, due to the fact that oracle uses it, but oracle client is writing there only after establishing the connection. The error that is thown by the php is the only valuable, and the oracle client keep silence. – Altenrion Oct 14 '15 at 09:30
  • @frz3993 I dont remember how to trace where php driver is trying to call file, and what file is he calling now. This error is showing the string in conf file that looks like thiss `/* something to hold errors */ OCIHandleAlloc(H->env, (dvoid **)&H->err, OCI_HTYPE_ERROR, 0, NULL); /* handle for the server */ OCIHandleAlloc(H->env, (dvoid **)&H->server, OCI_HTYPE_SERVER, 0, NULL); H->last_err = OCIServerAttach(H->server, H->err, (text*)vars[1].optval, strlen(vars[1].optval), OCI_DEFAULT); if (H->last_err) { oci_drv_error("pdo_oci_handle_factory"); goto cleanup; } ` – Altenrion Oct 14 '15 at 09:31
  • `/usr/local/src/php-5.3.3/ext/pdo_oci/oci_driver.c` ? – frz3993 Oct 14 '15 at 09:33
  • @frz3993 yes, `oci_drv_error("pdo_oci_handle_factory");` is the line that exception is pointing to – Altenrion Oct 14 '15 at 09:34
  • No, I mean does the file exist there, and with the correct permission ? – frz3993 Oct 14 '15 at 09:35
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/92233/discussion-between-altenrion-and-frz3993). – Altenrion Oct 14 '15 at 09:35
  • Any help is appreciated – Altenrion Oct 14 '15 at 12:58

0 Answers0