Segmentation fault when starting jvm using jpype

眉间皱痕 提交于 2019-12-11 05:35:49

问题


I am trying to use java sutime in my Python code. The code has been working fine until yesterday but now ends with Segmentation fault. The problem seems to be coming from

 jpype.startJVM(getDefaultJVMPath())

This function ends with Segmentation fault. The defaultJVMPath is

'/usr/lib/jvm/java-8-oracle/jre/lib/amd64/server/libjvm.so'

I have tried uninstalling and then installing java and jpype. The code works fine in virtual box with less memory, so the problem doesnt seems to be coming from lack of memory. Anyone has any ideas? Any help is appreciated., thanks!

>>> import jpype  
>>> jpype.isJVMStarted()  
0  
>>> jpype.startJVM(jpype.getDefaultJVMPath())  
Segmentation fault  
deepthi@deepthi:~$ 

回答1:


linux-image-3.13.0-121-generic and linux-image-4.4.0-81-generic contain a fix for the Stack Clash vulnerability.

Be careful with kernel updates, which fix this vulnerability. Current patch breaks many java (sun/oracle and openjdk) applications. See Bug #1699772: linux-image-4.4.0-81-generic, linux-image-3.13.0-121-generic Regression: many user-space apps crashing. The solution is to temporary reboot system with old kernel (linux-image-3.13.0-119-generic in Trusty / linux-image-4.4.0-78-generic in Xenial).

Ubuntu kernel developers will prepare new patch in a few days.

UPDATE: Latest updates (at least image-4.4.0-83-generic, linux-image-4.8.0-58-generic, linux-image-4.10.0-26-generic) fix this vulnerability and problems with user-space programs.



来源:https://stackoverflow.com/questions/44719488/segmentation-fault-when-starting-jvm-using-jpype

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!