如何在docker容器中使用python线程在多个Minecraft环境中运行多个代理?

当我尝试在多个Minecraft环境中使用docker容器中的python线程运行多个代理时,Minecraft启动器崩溃并退出。 在普通的桌面系统(非容器)和Python中的Python_Examples(无线程)在docker环境中工作相同的代码没有问题。 你有什么想法为什么发生

我收到了来自Minecraft发射器的错误消息,

# A fatal error has been detected by the Java Runtime Environment: # # SIGFPE (0x8) at pc=0x00007f2a8b48ce88, pid=3444, tid=0x00007f2ac7528700 # # JRE version: Java(TM) SE Runtime Environment (8.0_131-b11) (build 1.8.0_131-b11) # Java VM: Java HotSpot(TM) 64-Bit Server VM (25.131-b11 mixed mode linux-amd64 compressed oops) # Problematic frame: # C [swrast_dri.so+0x272e88] # # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again # # An error report file with more information is saved as: # /root/Malmo-0.21.0/Minecraft1/run/hs_err_pid3444.log # # If you would like to submit a bug report, please visit: # http://bugreport.java.com/bugreport/crash.jsp # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # :runClient FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':runClient'. > Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 134 * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 36.853 secs 

我运行docker如下使用GUI,

 xhost + ; docker run -it -p 8888:8888 -p 6006:6006 -p 8000:8000 -v `pwd`:/home/sharedfolder --privileged --device=/dev/snd:/dev/snd -v /tmp/.X11-unix:/tmp/.X11-unix:ro -e DISPLAY=unix$DISPLAY <container name> 

Interesting Posts