我有一台运行 Ubuntu 22.04 的 Dell R720 家庭实验室。它配备了以下 GPU:
$ nvidia-smi -L
GPU 0: Tesla P40 (UUID: GPU-ac45b921-3664-d911-5dd7-e5b8d49551c3)
GPU 1: Tesla P40 (UUID: GPU-11fdf0e4-2c22-162a-a65e-f594c9a908ae)
GPU 2: NVIDIA GeForce GT 710 (UUID: GPU-6fabed11-9de9-cd98-3220-658b45c1e7e8)
我想使用两个 P40 作为 CUDA 计算卡并让 GT 710 运行桌面环境,但我在设置 Xorg 和/或 Gnome 时遇到问题。特别是,GT 710 仅在显示器上输出壁纸,但我看不到其他任何内容:没有鼠标指针或登录窗口,并且它不响应鼠标移动或击键。像这样:
如何获得可用的桌面环境?
的输出nvidia-smi
Tue Feb 6 17:32:33 2024
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 470.223.02 Driver Version: 470.223.02 CUDA Version: 11.4 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 Tesla P40 On | 00000000:04:00.0 Off | Off |
| N/A 28C P8 9W / 250W | 22MiB / 24451MiB | 0% Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
| 1 Tesla P40 On | 00000000:42:00.0 Off | Off |
| N/A 29C P8 9W / 250W | 38MiB / 24451MiB | 0% Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
| 2 NVIDIA GeForce ... On | 00000000:44:00.0 N/A | N/A |
| 50% 31C P8 N/A / N/A | 424MiB / 2002MiB | N/A Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| 0 N/A N/A 97708 G /usr/lib/xorg/Xorg 22MiB |
| 1 N/A N/A 97708 G /usr/lib/xorg/Xorg 38MiB |
+-----------------------------------------------------------------------------+
内容在/etc/X11/xorg.conf
# nvidia-xconfig: X configuration file generated by nvidia-xconfig
# nvidia-xconfig: version 470.223.02
Section "ServerLayout"
Identifier "Layout0"
Screen 0 "Screen0"
InputDevice "Keyboard0" "CoreKeyboard"
InputDevice "Mouse0" "CorePointer"
Option "AutoAddGPU" "off"
EndSection
Section "Files"
EndSection
Section "InputDevice"
# generated from default
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "auto"
Option "Device" "/dev/psaux"
Option "Emulate3Buttons" "no"
Option "ZAxisMapping" "4 5"
EndSection
Section "InputDevice"
# generated from default
Identifier "Keyboard0"
Driver "kbd"
EndSection
Section "Monitor"
Identifier "Monitor0"
VendorName "Unknown"
ModelName "Unknown"
Option "DPMS"
EndSection
Section "Device"
Identifier "Device0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "Tesla P40"
BusID "PCI:4:0:0"
Option "Coolbits" "28"
EndSection
Section "Device"
Identifier "Device1"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "Tesla P40"
BusID "PCI:66:0:0"
Option "Coolbits" "28"
EndSection
Section "Device"
Identifier "Device2"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "NVIDIA GeForce GT 710"
BusID "PCI:68:0:0"
Option "Coolbits" "28"
EndSection
Section "Screen"
Identifier "Screen0"
Device "Device2"
Monitor "Monitor0"
DefaultDepth 24
SubSection "Display"
Depth 24
EndSubSection
EndSection
我无法将内容粘贴到~/.local/share/xorg/Xorg.0.log
此处,因为帖子限制为 30000 个字符,但您可以在 Pastebin 上看到它。
删除非图形计算 Tesla P40 中不必要且令人困惑的内容
/etc/X11/xorg.conf
:CUDA GPU 可以无头工作,因此不需要暴露于 X11。您的计算工作负载将直接与 Tesla 通信,而不需要通过现代 Linux 上的 X11。通过从 Xorg 配置中删除 Teslas,我们让 X11 专注于用于显示的 GT 710,并减少出错的空间。