在我从 18.04 更新(全新安装)到 20.04 之前,OBS 在我的 Nvidia Quadro K2100M 上运行良好。更新后,我遇到了以下消息。这发生在启动板和非官方 snap 版本中。我已从nvidia-driver-418-server
“附加驱动程序”安装了该软件包。任何帮助都将不胜感激。
从终端运行时,我收到以下消息:
info: ---------------------------------
info: [NVENC encoder: 'streaming_h264'] settings:
rate_control: CBR
bitrate: 2500
cqp: 0
keyint: 60
preset: hq
profile: high
width: 1280
height: 720
2-pass: false
b-frames: 2
GPU: 0
[h264_nvenc @ 0x563aff391b00] Driver does not support the required nvenc API version. Required: 9.1 Found: 9.0
[h264_nvenc @ 0x563aff391b00] The minimum required Nvidia driver for nvenc is 435.21 or newer
warning: [NVENC encoder: 'streaming_h264'] Failed to open NVENC codec: Function not implemented
uname -a
、、和的输出:inxi -G
lspci
obs --version
dpkg -l | egrep '(\ obs|libobs|nvidia)'
gekepdp@laptop:~$ uname -a Linux 笔记本电脑 5.8.0-55-通用 #62~20.04.1-Ubuntu SMP 星期三 6 月 2 日 08:55:04 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
gekepdp@laptop:~$ inxi-G 图形:设备-1:英特尔第四代酷睿处理器集成显卡司机:i915五:核心 设备-2:NVIDIA GK106GLM [Quadro K2100M]司机:英伟达五:460.80 展示:x11服务器:X.Org 1.20.9司机:模式设置,nvidia卸载:fbdev,新,vesa 解决:1920x1080~60Hz, 1920x1080~60Hz OpenGL的: 渲染器:Quadro K2100M/PCIe/SSE2五:4.6.0 NVIDIA 460.80
gekepdp@laptop:~$ lspci 00:00.0 主机桥:英特尔公司 Xeon E3-1200 v3/4th Gen Core 处理器 DRAM 控制器(rev 06) 00:01.0 PCI 桥:英特尔公司 Xeon E3-1200 v3/第四代酷睿处理器 PCI Express x16 控制器 (rev 06) 00:02.0 VGA 兼容控制器:英特尔公司第四代酷睿处理器集成图形控制器(rev 06) 00:03.0 音频设备:英特尔公司 Xeon E3-1200 v3/4th Gen Core 处理器高清音频控制器(rev 06) 00:14.0 USB 控制器:英特尔公司 8 系列/C220 系列芯片组家族 USB xHCI (rev 04) 00:16.0 通信控制器:英特尔公司 8 系列/C220 系列芯片组家族 MEI 控制器 #1(修订版 04) 00:19.0 以太网控制器:英特尔公司以太网连接 I217-LM(修订版 04) 00:1a.0 USB 控制器:英特尔公司 8 系列/C220 系列芯片组系列 USB EHCI #2 (rev 04) 00:1b.0 音频设备:英特尔公司 8 系列/C220 系列芯片组高清晰度音频控制器(rev 04) 00:1c.0 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #1 (rev d4) 00:1c.2 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #3 (rev d4) 00:1c.3 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #4 (rev d4) 00:1c.4 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #5 (rev d4) 00:1c.6 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #7 (rev d4) 00:1c.7 PCI 桥:英特尔公司 8 系列/C220 系列芯片组家族 PCI Express 根端口 #8 (rev d4) 00:1d.0 USB 控制器:英特尔公司 8 系列/C220 系列芯片组家族 USB EHCI #1 (rev 04) 00:1f.0 ISA 桥:英特尔公司 QM87 Express LPC 控制器(修订版 04) 00:1f.2 RAID 总线控制器:英特尔公司 82801 移动 SATA 控制器 [RAID 模式](修订版 04) 00:1f.3 SMBus:英特尔公司 8 系列/C220 系列芯片组系列 SMBus 控制器(修订版 04) 01:00.0 VGA 兼容控制器:NVIDIA Corporation GK106GLM [Quadro K2100M] (rev a1) 01:00.1 音频设备:NVIDIA Corporation GK106 HDMI 音频控制器(rev a1) 03:00.0 网络控制器:Broadcom Inc. 及其子公司 BCM4352 802.11ac 无线网络适配器(rev 03) 11:00.0 SD 主机控制器:O2 Micro, Inc. SD/MMC 读卡器控制器(rev 01)
gekepdp@laptop:~$ obs--版本 OBS Studio - 27.0.0(Linux)
gekepdp@laptop:~$ dpkg -l | egrep '(\ obs|libobs|nvidia)' ii lib英伟达-cfg1-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 二进制 OpenGL/GLX 配置库 ii lib英伟达-common-460 460.80-0ubuntu0.20.04.2 NVIDIA 库使用的所有共享文件 rc 库英伟达-compute-418-server:amd64 418.197.02-0ubuntu0.20.04.1 amd64 NVIDIA libcompute 包 ii lib英伟达-compute-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVIDIA libcompute 包 ii lib英伟达-compute-460:i386 460.80-0ubuntu0.20.04.2 i386 NVIDIA libcompute 包 ii lib英伟达-decode-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 视频解码运行时库 ii lib英伟达-decode-460:i386 460.80-0ubuntu0.20.04.2 i386 NVIDIA 视频解码运行库 ii lib英伟达-encode-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVENC 视频编码运行库 ii lib英伟达-encode-460:i386 460.80-0ubuntu0.20.04.2 i386 NVENC 视频编码运行库 ii lib英伟达-extra-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 驱动程序的额外库 ii lib英伟达-fbc1-460:amd64 460.80-0ubuntu0.20.04.2 amd64 基于 NVIDIA OpenGL 的帧缓冲区捕获运行库 ii lib英伟达-fbc1-460:i386 460.80-0ubuntu0.20.04.2 i386 基于 NVIDIA OpenGL 的帧缓冲区捕获运行库 ii lib英伟达-gl-460:amd64 460.80-0ubuntu0.20.04.2 amd64 NVIDIA OpenGL/GLX/EGL/GLES GLVND 库和 Vulkan ICD ii lib英伟达-gl-460:i386 460.80-0ubuntu0.20.04.2 i386 NVIDIA OpenGL/GLX/EGL/GLES GLVND 库和 Vulkan ICD ii lib英伟达-ifr1-460:amd64 460.80-0ubuntu0.20.04.2 amd64 基于 NVIDIA OpenGL 的带内帧读回运行时库 ii lib英伟达-ifr1-460:i386 460.80-0ubuntu0.20.04.2 i386 基于 NVIDIA OpenGL 的带内帧读回运行时库 rc 英伟达-compute-utils-418-server 418.197.02-0ubuntu0.20.04.1 amd64 NVIDIA 计算实用程序 二 英伟达-compute-utils-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 计算实用程序 rc 英伟达-dkms-418-server 418.197.02-0ubuntu0.20.04.1 amd64 NVIDIA DKMS 软件包 二 英伟达-dkms-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA DKMS 软件包 二 英伟达-driver-435 455.45.01-0ubuntu0.20.04.1 amd64 过渡包英伟达-驱动程序-455 二 英伟达-driver-455 460.80-0ubuntu0.20.04.2 amd64 过渡包英伟达-驱动程序-460 二 英伟达-driver-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 驱动程序元包 rc 英伟达-kernel-common-418-server 418.197.02-0ubuntu0.20.04.1 amd64 与内核模块一起使用的共享文件 二 英伟达-kernel-common-460 460.80-0ubuntu0.20.04.2 amd64 与内核模块一起使用的共享文件 二 英伟达-kernel-source-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 内核源码包 二 英伟达-prime 0.8.16~0.20.04.1 所有启用 NVIDIA Prime 的工具 二 英伟达-settings 460.39-0ubuntu0.20.04.1 amd64 配置NVIDIA显卡驱动的工具 二 英伟达-utils-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 驱动程序支持二进制文件 二观察-studio 27.0.0-0obsproject1~focal amd64 适用于 Ubuntu 的 OBS Studio ii screen-resolution-extra 0.18build1 all 扩展英伟达-设置控制面板 ii xserver-xorg-video-英伟达-460 460.80-0ubuntu0.20.04.2 amd64 NVIDIA 二进制 Xorg 驱动程序
OBS 命令的完整输出如下 - 我尝试录制,然后在失败后退出程序:
Attempted path: share/obs/obs-studio/locale/en-US.ini
Attempted path: /usr/share/obs/obs-studio/locale/en-US.ini
Attempted path: share/obs/obs-studio/locale.ini
Attempted path: /usr/share/obs/obs-studio/locale.ini
Attempted path: share/obs/obs-studio/locale/en-GB.ini
Attempted path: /usr/share/obs/obs-studio/locale/en-GB.ini
info: Using preferred locale 'en-GB'
Attempted path: share/obs/obs-studio/themes/Dark.qss
Attempted path: /usr/share/obs/obs-studio/themes/Dark.qss
info: CPU Name: Intel(R) Core(TM) i7-4600M CPU @ 2.90GHz
info: CPU Speed: 2984.634MHz
info: Physical Cores: 2, Logical Cores: 4
info: Physical Memory: 15918MB Total, 11543MB Free
info: Kernel Version: Linux 5.8.0-55-generic
info: Distribution: "Ubuntu" "20.04"
info: Session Type: x11
info: Window System: X11.0, Vendor: The X.Org Foundation, Version: 1.20.9
info: Portable mode: false
Attempted path: share/obs/obs-studio/themes/Dark/no_sources.svg
Attempted path: /usr/share/obs/obs-studio/themes/Dark/no_sources.svg
QMetaObject::connectSlotsByName: No matching signal for on_tbar_position_valueChanged(int)
QMetaObject::connectSlotsByName: No matching signal for on_actionShowTransitionProperties_triggered()
QMetaObject::connectSlotsByName: No matching signal for on_actionHideTransitionProperties_triggered()
info: OBS 27.0.0 (linux)
info: ---------------------------------
info: ---------------------------------
info: audio settings reset:
samples per sec: 48000
speakers: 2
info: ---------------------------------
info: Initializing OpenGL...
info: Loading up OpenGL on adapter NVIDIA Corporation Quadro K2100M/PCIe/SSE2
info: OpenGL loaded successfully, version 3.3.0 NVIDIA 460.80, shading language 3.30 NVIDIA via Cg compiler
info: ---------------------------------
info: video settings reset:
base resolution: 1920x1080
output resolution: 1280x720
downscale filter: Bicubic
fps: 30/1
format: NV12
YUV mode: 709/Partial
info: NV12 texture support not available
info: Audio monitoring device:
name: Default
id: default
info: ---------------------------------
warning: Failed to load 'en-US' text for module: 'decklink-captions.so'
warning: Failed to load 'en-US' text for module: 'decklink-ouput-ui.so'
libDeckLinkAPI.so: cannot open shared object file: No such file or directory
warning: A DeckLink iterator could not be created. The DeckLink drivers may not be installed
info: No blackmagic support
info: [obs-browser]: Version 2.14.3
info: [obs-browser]: CEF Version 87.1.12+g03f9336+chromium-87.0.4280.88
info: NVENC supported
info: FFMPEG VAAPI supported
info: VLC found, VLC video source enabled
info: ---------------------------------
info: Loaded Modules:
info: vlc-video.so
info: text-freetype2.so
info: rtmp-services.so
info: obs-x264.so
info: obs-vst.so
info: obs-transitions.so
info: obs-outputs.so
info: obs-libfdk.so
info: obs-filters.so
info: obs-ffmpeg.so
info: obs-browser.so
info: linux-v4l2.so
info: linux-pulseaudio.so
info: linux-jack.so
info: linux-decklink.so
info: linux-capture.so
info: linux-alsa.so
info: image-source.so
info: frontend-tools.so
info: decklink-ouput-ui.so
info: decklink-captions.so
info: ---------------------------------
info: ==== Startup complete ===============================================
info: All scene data cleared
info: ------------------------------------------------
info: pulse-input: Server name: 'pulseaudio 13.99.1'
info: pulse-input: Audio format: s16le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_output.pci-0000_00_1b.0.analog-stereo.monitor'
info: [Loaded global audio device]: 'Desktop Audio'
info: pulse-input: Server name: 'pulseaudio 13.99.1'
info: pulse-input: Audio format: s16le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_input.pci-0000_00_1b.0.analog-stereo'
info: [Loaded global audio device]: 'Mic/Aux'
info: Switched to scene 'Scene'
info: ------------------------------------------------
info: Loaded scenes:
info: - scene 'Scene':
info: ------------------------------------------------
Attempted path: share/obs/obs-studio/images/overflow.png
Attempted path: /usr/share/obs/obs-studio/images/overflow.png
info: adding 42 milliseconds of audio buffering, total audio buffering is now 42 milliseconds (source: Mic/Aux)
info: ---------------------------------
info: [NVENC encoder: 'streaming_h264'] settings:
rate_control: CBR
bitrate: 2500
cqp: 0
keyint: 60
preset: hq
profile: high
width: 1280
height: 720
2-pass: false
b-frames: 2
psycho-aq: 1
GPU: 0
[h264_nvenc @ 0x55c81e3a2800] No NVENC capable devices found
warning: [NVENC encoder: 'streaming_h264'] Failed to open NVENC codec: Generic error in an external library
info: ==== Shutting down ==================================================
info: pulse-input: Stopped recording from 'alsa_output.pci-0000_00_1b.0.analog-stereo.monitor'
info: pulse-input: Got 2034 packets with 450092 frames
info: pulse-input: Stopped recording from 'alsa_input.pci-0000_00_1b.0.analog-stereo'
info: pulse-input: Got 1216 packets with 537216 frames
info: All scene data cleared
info: ------------------------------------------------
error: X Error: GLXBadDrawable, Major opcode: 152, Minor opcode: 26, Serial: 5359
error: Failed to make context current.
error: X Error: GLXBadDrawable, Major opcode: 152, Minor opcode: 26, Serial: 5361
error: Failed to make context current.
error: X Error: GLXBadDrawable, Major opcode: 152, Minor opcode: 26, Serial: 5363
error: Failed to make context current.
info: [Scripting] Total detached callbacks: 0
info: Freeing OBS context data
info: == Profiler Results =============================
info: run_program_init: 882.557 ms
info: ┣OBSApp::AppInit: 6.888 ms
info: ┃ ┗OBSApp::InitLocale: 3.603 ms
info: ┗OBSApp::OBSInit: 684.271 ms
info: ┣obs_startup: 1.393 ms
info: ┗OBSBasic::OBSInit: 615.277 ms
info: ┣OBSBasic::InitBasicConfig: 0.49 ms
info: ┣OBSBasic::ResetAudio: 0.182 ms
info: ┣OBSBasic::ResetVideo: 80.406 ms
info: ┣OBSBasic::InitOBSCallbacks: 0.002 ms
info: ┣OBSBasic::InitHotkeys: 0.059 ms
info: ┣obs_load_all_modules: 346.455 ms
info: ┃ ┣obs_init_module(decklink-captions.so): 0.041 ms
info: ┃ ┣obs_init_module(decklink-ouput-ui.so): 0.634 ms
info: ┃ ┣obs_init_module(frontend-tools.so): 92.523 ms
info: ┃ ┣obs_init_module(image-source.so): 0.009 ms
info: ┃ ┣obs_init_module(linux-alsa.so): 0.004 ms
info: ┃ ┣obs_init_module(linux-capture.so): 0.405 ms
info: ┃ ┣obs_init_module(linux-decklink.so): 0.18 ms
info: ┃ ┣obs_init_module(linux-jack.so): 0.003 ms
info: ┃ ┣obs_init_module(linux-pulseaudio.so): 0.002 ms
info: ┃ ┣obs_init_module(linux-v4l2.so): 2.865 ms
info: ┃ ┣obs_init_module(obs-browser.so): 0.077 ms
info: ┃ ┣obs_init_module(obs-ffmpeg.so): 12.192 ms
info: ┃ ┃ ┗nvenc_check: 12.08 ms
info: ┃ ┣obs_init_module(obs-filters.so): 0.029 ms
info: ┃ ┣obs_init_module(obs-libfdk.so): 0.003 ms
info: ┃ ┣obs_init_module(obs-outputs.so): 0.005 ms
info: ┃ ┣obs_init_module(obs-transitions.so): 0.011 ms
info: ┃ ┣obs_init_module(obs-vst.so): 0.004 ms
info: ┃ ┣obs_init_module(obs-x264.so): 0.002 ms
info: ┃ ┣obs_init_module(rtmp-services.so): 2.054 ms
info: ┃ ┣obs_init_module(text-freetype2.so): 0.018 ms
info: ┃ ┗obs_init_module(vlc-video.so): 2.761 ms
info: ┣OBSBasic::ResetOutputs: 0.565 ms
info: ┣OBSBasic::CreateHotkeys: 0.197 ms
info: ┣OBSBasic::InitService: 2.12 ms
info: ┣OBSBasic::InitPrimitives: 0.226 ms
info: ┗OBSBasic::Load: 87.471 ms
info: obs_hotkey_thread(25 ms): min=0.119 ms, median=0.471 ms, max=5.055 ms, 99th percentile=1.343 ms, 100% below 25 ms
info: audio_thread(Audio): min=0 ms, median=0.091 ms, max=1.339 ms, 99th percentile=0.5 ms
info: obs_graphics_thread(33.3333 ms): min=0.372 ms, median=1.53 ms, max=43.953 ms, 99th percentile=6.607 ms, 99.7375% below 33.333 ms
info: ┣tick_sources: min=0.001 ms, median=0.009 ms, max=0.193 ms, 99th percentile=0.024 ms
info: ┣output_frame: min=0.129 ms, median=0.389 ms, max=5.725 ms, 99th percentile=2.224 ms
info: ┃ ┗gs_context(video->graphics): min=0.129 ms, median=0.388 ms, max=5.724 ms, 99th percentile=2.222 ms
info: ┃ ┣render_video: min=0.058 ms, median=0.111 ms, max=0.866 ms, 99th percentile=0.506 ms
info: ┃ ┃ ┗render_main_texture: min=0.048 ms, median=0.09 ms, max=0.846 ms, 99th percentile=0.321 ms
info: ┃ ┗gs_flush: min=0.006 ms, median=0.015 ms, max=0.199 ms, 99th percentile=0.059 ms
info: ┗render_displays: min=0.061 ms, median=0.703 ms, max=41.419 ms, 99th percentile=2.389 ms
info: =================================================
info: == Profiler Time Between Calls ==================
info: obs_hotkey_thread(25 ms): min=25.2 ms, median=25.58 ms, max=30.172 ms, 34.2% within ±2% of 25 ms (0% lower, 65.8% higher)
info: obs_graphics_thread(33.3333 ms): min=22.719 ms, median=33.333 ms, max=43.957 ms, 99.4737% within ±2% of 33.333 ms (0.263158% lower, 0.263158% higher)
info: =================================================
info: Number of memory leaks: 0
答案1
看起来您的硬件不支持所需的 nvenc 版本,请在设置中更改编码器。
答案2
编辑2:请发布以下命令的完整输出:
$ obs
请发布以下命令的完整输出:
$ uname -a
$ inxi -G
$ lspci
$ obs --version
$ dpkg -l | egrep '(\ obs|libobs|nvidia)'
你似乎有一个旧的 nvidia 驱动程序。可能有效的方法如下:
sudo apt update
sudo apt remove '^nvidia'
sudo apt autoremove
sudo apt install nvidia-driver-465
sudo reboot
注意:我之所以发布是465
因为这是我在输入 后看到的最新版本,并且带有制表符补全sudo apt install nvidia-driver-
。您可能拥有不同的版本,但它肯定足够了(可能 >435)(来源)。
我认为你不需要从源代码编译。