N
N
Nikolay Baranenko2017-04-19 18:31:31
Python
Nikolay Baranenko, 2017-04-19 18:31:31

Why did the Unable to load DLL [C:\Program Files\Java\jre1.8.0_131\bin\server\jvm.dll] error occur?

Hello.
Today I installed JVM 8u131 x64 and x86 + python-3.6.1-amd64 on clean windows 2012 R2 Standard.
There is a script in python that clings to Oracle via JDBC

import jpype
import jaydebeapi

jHome = jpype.getDefaultJVMPath()
jpype.startJVM(jHome, '-Djava.class.path='+PATH_LIB)
conn = jaydebeapi.connect('oracle.jdbc.driver.OracleDriver', URL_CONNECTION,[USERNAME,PASSWORD])
curs = conn.cursor()
curs.execute(sql_script)
....

on other windows 2012 R2 it works fine (on windows 10 also without problems),
BUT on this installation, windows began to return an error
Traceback (most recent call last):
  File "C:/Server/repositories/projects/um/templates/DB/Oracle/Oracle_JDBC.py", line 84, in <module>
    jpype.startJVM(jHome, '-Djava.class.path='+PATH_LIB)
  File "C:\Python36\lib\site-packages\jpype\_core.py", line 50, in startJVM
    _jpype.startup(jvm, tuple(args), True)
RuntimeError: Unable to load DLL [C:\Program Files\Java\jre1.8.0_131\bin\server\jvm.dll], error = The specified module could not be found.
 at native\common\include\jp_platform_win32.h:58

I checked jvm, dll in place, there are rights too ...
What could be the problem and how to solve it?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question