6

我正在尝试在 Amazon EC2 上的 Ubuntu 实例中通过 Xvfb 运行 ParaView。我已经按照http://mike.ucoz.com/publ/programming/ubuntu/selenium_ubuntu_amazon_ec2_headless/8-1-0-4安装了 X11/Xvfb 相关的软件包

但我似乎无法克服与 swrast 库相关的错误。

这是启动 Xfvb 时的消息

$ export DISPLAY=:99
$ Xvfb $DISPLAY &
Initializing built-in extension Generic Event Extension
Initializing built-in extension SHAPE
Initializing built-in extension MIT-SHM
Initializing built-in extension XInputExtension
Initializing built-in extension XTEST
Initializing built-in extension BIG-REQUESTS
Initializing built-in extension SYNC
Initializing built-in extension XKEYBOARD
Initializing built-in extension XC-MISC
Initializing built-in extension SECURITY
Initializing built-in extension XINERAMA
Initializing built-in extension XFIXES
Initializing built-in extension RENDER
Initializing built-in extension RANDR
Initializing built-in extension COMPOSITE
Initializing built-in extension DAMAGE
Initializing built-in extension MIT-SCREEN-SAVER
Initializing built-in extension DOUBLE-BUFFER
Initializing built-in extension RECORD
Initializing built-in extension DPMS
Initializing built-in extension X-Resource
Initializing built-in extension XVideo
Initializing built-in extension XVideo-MotionCompensation
Initializing built-in extension SELinux
Initializing built-in extension GLX
[dix] Could not init font path element /var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType, removing from list!

我在上面看不到任何戏剧性的东西。但是在运行 glxinfo 时

$ glxinfo
name of display: :99
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/tls/swrast_dri.so
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/swrast_dri.so
libGL error: failed to load driver: swrast
Error: couldn't find RGB GLX visual or fbconfig

144 GLXFBConfigs:
    visual  x   bf lv rg d st  colorbuffer  sr ax dp st accumbuffer  ms  cav

笔记:

$ ls /usr/lib/x86_64-linux-gnu/dri/
dummy_drv_video.so  nouveau_dri.so        r300_dri.so    radeonsi_dri.so
i915_dri.so         nouveau_vieux_dri.so  r600_dri.so    swrast_dri.so
i965_dri.so         r200_dri.so           radeon_dri.so  vmwgfx_dri.so

提前致谢。

4

2 回答 2

1

假设您已经xvfb-run安装,您可以尝试:

xvfb-run --auto-servernum -s "-screen 0 640x480x24" <something_that_needs_X11> 

来源:https ://bugzilla.redhat.com/show_bug.cgi?id=904851#c5

于 2016-09-20T13:04:21.160 回答
0

Amazon EC2 使用 Nvidia GPU,因此问题可能是由 NV 驱动程序引起的。

试一试,使用 docker 容器运行它,基于我的 dockerfile Dockerfile_cuda80

此 dockerfile 基于官方 cuda 映像,修改为使用 OpenGL 运行所有 cuda 示例,您应该使用 nvidia-docker 构建和运行它。

这解决了我在通过 WINE 运行 Windows 程序时遇到的类似问题。

于 2017-10-31T09:45:35.110 回答