python - Why is python interpreter not working on Zeppelin 0.8.0 for any of my notebooks?
问题描述
I am simply typing:
%python
print ("hi")
but it keeps showing the following error every time I run it for any of my notebooks:
java.lang.OutOfMemoryError: Java heap space at org.apache.thrift.protocol.TBinaryProtocol.readStringBody(TBinaryProtocol.java:379) at org.apache.thrift.protocol.TBinaryProtocol.readMessageBegin(TBinaryProtocol.java:230) at org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java:69) at org.apache.zeppelin.interpreter.thrift.RemoteInterpreterService$Client.recv_createInterpreter(RemoteInterpreterService.java:209) at org.apache.zeppelin.interpreter.thrift.RemoteInterpreterService$Client.createInterpreter(RemoteInterpreterService.java:192) at org.apache.zeppelin.interpreter.remote.RemoteInterpreter$2.call(RemoteInterpreter.java:169) at org.apache.zeppelin.interpreter.remote.RemoteInterpreter$2.call(RemoteInterpreter.java:165) at org.apache.zeppelin.interpreter.remote.RemoteInterpreterProcess.callRemoteFunction(RemoteInterpreterProcess.java:135) at org.apache.zeppelin.interpreter.remote.RemoteInterpreter.internal_create(RemoteInterpreter.java:165) at org.apache.zeppelin.interpreter.remote.RemoteInterpreter.open(RemoteInterpreter.java:132) at org.apache.zeppelin.interpreter.remote.RemoteInterpreter.getFormType(RemoteInterpreter.java:299) at org.apache.zeppelin.notebook.Paragraph.jobRun(Paragraph.java:407) at org.apache.zeppelin.scheduler.Job.run(Job.java:188) at org.apache.zeppelin.scheduler.RemoteScheduler$JobRunner.run(RemoteScheduler.java:307) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source)
I am trying to use python on my notebooks on Zeppelin. I have both java and python paths added to my Environment Variables, and I have the library py4j installed, too. Also I have added the local host that I am using to the Zeppelin-site.xml file. I also found this link on a similar issue on Stack Overflow and tried everything in it to change the size of the java space but still didn't work. http://apache-zeppelin-users-incubating-mailing-list.75479.x6.nabble.com/Can-not-configure-driver-memory-size-td1513.html
Any little help is much appreciated!
解决方案
I was able to get past the above error by using a fresh download of Zeppelin. I did run into another issue however when trying to use the python interpreter: Apache Zeppelin 8.1 Win10 Python Interpreter Error
The stack trace in the cmd window used to launch Zeppelin revealed the follow error: Apache Zeppelin 8.1 Win10 Python Interpreter Error Stack Trace
Basically by referencing the code I was able to see the python interpreter is attempting to create a temporary file and put into a folder named tmp: https://github.com/apache/zeppelin/blob/branch-0.8/python/src/main/java/org/apache/zeppelin/python/PythonInterpreter.java, line 102
From this point I wasn't sure where it was trying use this folder named tmp. On my PC the location ended up being in root of C, so C:\tmp
推荐阅读
- windows - 将 ETW 事件记录到事件查看器
- postgresql - 在postgresql中,我需要一个月中的所有偶数天和一个月中的所有奇数天
- loops - 轻松循环 ElasticSearch 文档源数组
- webpack - 在 CRA Monorepo 中摇树
- javascript - 操作对象的数组值
- oracle11g - 如何防止 sql ant 任务为左连接表的不匹配行字段打印“null”
- vb.net - Try...Catch 块,用于处理导入时格式不正确的 Excel 数据的触发错误
- javascript - ParcelJS - 未捕获的 ReferenceError:未定义滑块
- visual-studio-2017 - 使用 ADOX Microsoft Access 的 Visual Studio 2017 应用程序中的 System.Runtime.InteropServices.COMException 错误
- c# - 如何在不使用 Azure Key Vault 或 User Secrets Manager 的情况下使用 React 在 ASP.net 中安全地隐藏我的 API 密钥?