php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #79775 Unable to load dynamic library 'php_oci8_12c.dll'
Submitted: 2020-07-03 12:07 UTC Modified: 2020-07-15 06:07 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: thomas dot wiedmann at laek-bw dot de Assigned: cmb (profile)
Status: Not a bug Package: Oracle related
PHP Version: 7.4.7 OS: Windows NT 10.0 build 14393
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: thomas dot wiedmann at laek-bw dot de
New email:
PHP Version: OS:

 

 [2020-07-03 12:07 UTC] thomas dot wiedmann at laek-bw dot de
Description:
------------
Apache is unable to load dynamic library 'php_oci8_12c.dll' 


========
Apache 2.4.33 error.log:   (httpd-2.4.33-win64-VC15.zip)
--------------------------------------------------------
PHP Warning:  PHP Startup: Unable to load dynamic library 'php_oci8_12c.dll' (tried: c:/Program Files/AERUS/php-7.4.7-Win32-vc15-x64/ext\\php_oci8_12c.dll (Die angegebene Prozedur wurde nicht gefunden.), c:/Program Files/AERUS/php-7.4.7-Win32-vc15-x64/ext\\php_php_oci8_12c.dll.dll (Das angegebene Modul wurde nicht gefunden.)) in Unknown on line 0

OS: Windows NT 10.0 build 14393 (Windows Server 2016) AMD64  64-Bit

Any hint to debug this?


Test script:
---------------
<?php
 phpinfo();
?>



Expected result:
----------------
<?php
 phpinfo();
?>

load php_oci8_12c.dll

Actual result:
--------------
Unable to load dynamic library 'php_oci8_12c.dll'

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-07-03 12:20 UTC] thomas dot wiedmann at laek-bw dot de
This pecl .dll is in use:

https://pecl.php.net/package/oci8/2.2.0/windows
oci8 2.2.0 for Windows
7.4 Thread Safe (TS) x64
 [2020-07-03 12:29 UTC] cmb@php.net
-Status: Open +Status: Feedback -Package: PECL +Package: Oracle related -Assigned To: +Assigned To: cmb
 [2020-07-03 12:29 UTC] cmb@php.net
Use deplister.exe (contained in all PHP downloads from
windows.php.net) to check for the dependencies of php_oci8_12.dll:

    deplister php_oci8_12.dll

I assume that OCI.dll is not in your PATH.
 [2020-07-03 12:33 UTC] cmb@php.net
-Assigned To: cmb +Assigned To: sixd
 [2020-07-03 12:33 UTC] cmb@php.net
Hmm, I wonder what's the difference between ext/oci8 and
PECL/oci8.
 [2020-07-03 12:41 UTC] thomas dot wiedmann at laek-bw dot de
-Status: Feedback +Status: Assigned
 [2020-07-03 12:41 UTC] thomas dot wiedmann at laek-bw dot de
Don't now - deplister show nothing. Maybe I have to ask my admin?
---------

X:\AERUS\php-7.4.7-Win32-vc15-x64>deplister.exe ext\php_oci8_12.dll

X:\AERUS\php-7.4.7-Win32-vc15-x64>pause
Drücken Sie eine beliebige Taste . . .

-----------------


Look on my phpinfo() - Apache Environment - Path:
------------
C:\oracle\product\11.2.0\client_1\bin;C:\oracle\product\11.2.0\client_1;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps
 [2020-07-03 12:47 UTC] thomas dot wiedmann at laek-bw dot de
phpinfo();
PDO_OCI is loaded well.
 [2020-07-03 13:17 UTC] cmb@php.net
> Don't now - deplister show nothing.

If the DLL doesn't exist, deplister shows nothing for me as well.
Otherwise I get (regardless of having the orinally delivered DLL
or the PECL one):

D:\Users\cmb\Downloads\php-7.4.7-Win32-vc15-x64>deplister ext\php_oci8_12c.dll
php7ts.dll,OK
OCI.dll,NOTFOUND
VCRUNTIME140.dll,OK
api-ms-win-crt-heap-l1-1-0.dll,OK
api-ms-win-crt-time-l1-1-0.dll,OK
api-ms-win-crt-string-l1-1-0.dll,OK
api-ms-win-crt-runtime-l1-1-0.dll,OK
api-ms-win-crt-stdio-l1-1-0.dll,OK
KERNEL32.dll,OK

> phpinfo();
> PDO_OCI is loaded well.

Then the error message should no longer occur.
 [2020-07-04 00:00 UTC] sixd@php.net
There are more questions than answers. You are using php_oci8_12c.dll but only have Oracle version 11 in PATH.  You may need the correct VS redistributable.  There are a bunch of questions/answers best followed up outside the bug system.  Please ask on a forum such as https://www.oracle.com/database/technologies/appdev/php.html before we investigate as a bug.
 [2020-07-04 00:00 UTC] sixd@php.net
There are more questions than answers. You are using php_oci8_12c.dll but only have Oracle version 11 in PATH.  You may need the correct VS redistributable.  There are a bunch of questions/answers best followed up outside the bug system.  Please ask on a forum such as https://www.oracle.com/database/technologies/appdev/php.html before we investigate as a bug.
 [2020-07-08 08:56 UTC] thomas dot wiedmann at laek-bw dot de
Ok, now I have checked these two DLLs with deplister.exe. Both find the OCI.DLL and the error in Apache error.og still exists.

[1. Test]--------------------------------------------------
deplister ext\php_oci8_11g.dll
C:\Program Files\AERUS\php-7.4.7-Win32-vc15-x64>deplister ext\php_oci8_11g.dll
php7ts.dll,OK
OCI.dll,OK
VCRUNTIME140.dll,OK
api-ms-win-crt-heap-l1-1-0.dll,NOTFOUND
api-ms-win-crt-time-l1-1-0.dll,NOTFOUND
api-ms-win-crt-string-l1-1-0.dll,NOTFOUND
api-ms-win-crt-runtime-l1-1-0.dll,NOTFOUND
api-ms-win-crt-stdio-l1-1-0.dll,NOTFOUND
KERNEL32.dll,OK

[2. Test]--------------------------------------------------
deplister ext\php_oci8_12c.dll

C:\Program Files\AERUS\php-7.4.7-Win32-vc15-x64>deplister ext\php_oci8_12c.dll
php7ts.dll,OK
OCI.dll,OK
VCRUNTIME140.dll,OK
api-ms-win-crt-heap-l1-1-0.dll,NOTFOUND
api-ms-win-crt-time-l1-1-0.dll,NOTFOUND
api-ms-win-crt-string-l1-1-0.dll,NOTFOUND
api-ms-win-crt-runtime-l1-1-0.dll,NOTFOUND
api-ms-win-crt-stdio-l1-1-0.dll,NOTFOUND
KERNEL32.dll,OK

C:\Program Files\AERUS\php-7.4.7-Win32-vc15-x64>dir


[php.ini]------------------------------------
php.ini changed to php_oci8_11g

; 03.07.2020 TW
;extension=php_oci8_12c 
extension=php_oci8_11g  

[Apache Error.log]------------
PHP Warning:  PHP Startup: Failed to load c:/Program Files/AERUS/php-7.4.7-Win32-vc15-x64/ext\\php_oci8_11g, Das System kann die angegebene Datei nicht finden.\r\n in Unknown on line 0


[phpinfo]---------------
phpinfo();
don't listed OCI
listed PDO_OCI
 [2020-07-08 09:59 UTC] cmb@php.net
-Status: Assigned +Status: Not a bug -Assigned To: sixd +Assigned To: cmb
 [2020-07-08 09:59 UTC] cmb@php.net
> api-ms-win-crt-heap-l1-1-0.dll,NOTFOUND
> api-ms-win-crt-time-l1-1-0.dll,NOTFOUND
> api-ms-win-crt-string-l1-1-0.dll,NOTFOUND
> api-ms-win-crt-runtime-l1-1-0.dll,NOTFOUND
> api-ms-win-crt-stdio-l1-1-0.dll,NOTFOUND

That's strange, because these are needed anyway.  You may need to
update the Visual C++ Redistributable for Visual Studio.

Anyhow, I don't think there is a bug regarding PHP/PECL, so you're
better off asking in a support forum.  Thanks.
 [2020-07-14 13:50 UTC] phpdev at ehrhardt dot nl
>> phpinfo();
>> PDO_OCI is loaded well.
>
>Then the error message should no longer occur.

Not really. php_pdo_oci.dll is fairly tolerant. For instance, it loads OK with a too old OCI.dll, while php_oci8_12c.dll exits with a missing procedure:

PHP Warning:  PHP Startup: Unable to load dynamic library 'oci8_12c' (tried: ext\oci8_12c (The specified module could not be found.), ext\php_oci8_12c.dll (The specified procedure could not be found.)) in Unknown on line 0

There seems to be no difference between the PHP- and the PECL-versions, allthough they differ quite a lot in size (150 KB vs 158 KB).

Anyway, (re)installing the VC++ Redistributable seems at least required: https://aka.ms/vs/16/release/VC_redist.x64.exe
 [2020-07-14 13:55 UTC] phpdev at ehrhardt dot nl
> Die angegebene Prozedur wurde nicht gefunden.

translates to 

> The specified procedure could not be found.

Which indicates a too old OCI.dll. Looling at the other comment it is a 11g OCI.dll while php_oci8_12c.dll requires a 12c OCI.dll.
 [2020-07-15 06:07 UTC] thomas dot wiedmann at laek-bw dot de
Thank you for your help, tips and information. The problem seems to be very specific and is related to Windows Server 2016. This is a newly set up server. The update file VC_redist.x64.exe I have installed and repaired in the meantime (several times). The missing api-ms-win-crt-*.dlls are still missing.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 12:01:31 2024 UTC