gpt4 book ai didi

ubuntu - 使用 Ubuntu 在 AWS GPU 实例上运行 OpenGL

转载 作者:太空宇宙 更新时间:2023-11-03 16:44:06 28 4
gpt4 key购买 nike

我正在尝试让 opengl 在使用 Ubuntu Ubuntu Server 16.04 的 Amazon p2 实例上进行 headless (headless)屏幕外渲染。

创建实例后,我根据 this amazon article 安装了适当的 nvidia 驱动程序,它们似乎按预期工作:

$ lsmod | grep nvidia
nvidia_drm 53248 0
nvidia_modeset 790528 1 nvidia_drm
nvidia 11911168 1 nvidia_modeset
drm_kms_helper 155648 3 cirrus,nouveau,nvidia_drm
drm 364544 7 ttm,drm_kms_helper,cirrus,nouveau,nvidia_drm

$ nvidia-smi -q | head
==============NVSMI LOG==============

Timestamp : Thu Jan 19 11:22:38 2017
Driver Version : 375.20

Attached GPUs : 1
GPU 0000:00:1E.0
Product Name : Tesla K80
Product Brand : Tesla

然后我正在尝试 this related question 中的步骤:

sudo apt-get install xserver-xorg libglu1-mesa-dev freeglut3-dev mesa-common-dev libxmu-dev libxi-dev
sudo nvidia-xconfig -a --use-display-device=None --virtual=1280x1024
sudo /usr/bin/X :0 &

它确实启动了 X 但运行 glxinfo 不起作用:

$ DISPLAY=:0 glxinfo
name of display: :0
Xlib: extension "GLX" missing on display ":0".
Xlib: extension "GLX" missing on display ":0".
(... line repeats couple of times ...)
Error: couldn't find RGB GLX visual or fbconfig

如相关 stackoverflow 问题中所述,更改 Xorg.conf 中的 BusID 没有帮助。

$ lspci|grep VGA
00:02.0 VGA compatible controller: Cirrus Logic GD 5446

/etc/X11/xorg.conf
Section "Device"
Identifier "Device0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "Tesla K80"
BusID "PCI:0:2:0"
EndSection

我已经在谷歌上进行了相当深入的搜索,但我不清楚下一步该怎么做...任何帮助将不胜感激

最佳答案

官方文档是http://www.nvidia.com/content/PDF/remote-viz-tesla-gpus.pdf “服务器级 TESLA GPU 上的远程可视化”。阅读第 15 页。您必须将 BusID 添加到 nvidia-xconfig。

首先,运行 nvidia-xconfig --query-gpu-info。这是我的 p2 实例结果。

Number of GPUs: 1

GPU #0:
Name : Tesla K80
UUID : GPU-f13e8e90-5d2f-f9fb-b7a8-39edf9500698
PCI BusID : PCI:0:30:0

Number of Display Devices: 0

然后你需要运行它。

sudo nvidia-xconfig --busid=PCI:0:30:0 --use-display-device=none --virtual=1280x1024

您可以通过 sudo Xorg :1 运行 Xorg 服务器。

DISPLAY=:1 glxinfo 结果。

name of display: :1
display: :1 screen: 0
direct rendering: Yes
server glx vendor string: NVIDIA Corporation
server glx version string: 1.4
server glx extensions:
GLX_ARB_context_flush_control, GLX_ARB_create_context,
...

关于ubuntu - 使用 Ubuntu 在 AWS GPU 实例上运行 OpenGL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41741100/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com