我现在已经使用Ubuntu 20.04超过一个月了。 重启后,我没有声音和WiFi。请注意,这与许多其他帖子不同,它们似乎在升级后没有声音。在这种情况下,声音仅在重新启动后停止工作。
至于声音,我似乎没有适用于声音的适当内核模块,所以我猜最有可能的解决方案是使这些模块可用(看起来我有两个声卡)。 我将尽量在下面(1)包含与大量类似问题的帖子相关的尽可能多的信息。
我在下面(2)列出了一些我认为在当前修复工作进行时最有用的帖子。
我在下面(3)列出了其他一些曾经参考过的帖子,当问题更为棘手时。
(1)关于我损坏的系统的信息,以及我成功组装的工作系统的比较。
- 没有
/proc/asound
目录。
相对应的是
$ cat /proc/asound/cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0x604b108000 irq 159
1 [NVidia ]: HDA-Intel - HDA NVidia
HDA NVidia at 0xa4000000 irq 17
2.
$ lsmod | grep snd
输出为空。
对比(还可以与this进行比较)
$ lsmod | grep snd_hda_intel
snd_hda_intel 53248 10
snd_intel_dspcfg 24576 3 snd_hda_intel,snd_sof_pci,snd_sof_intel_hda_common
snd_hda_codec 131072 5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek,snd_soc_hdac_hda
snd_hda_core 90112 9 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_ext_core,snd_hda_codec,snd_hda_codec_realtek,snd_sof_intel_hda_common,snd_soc_hdac_hda,snd_sof_intel_hda
snd_pcm 106496 9 snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_sof,snd_sof_intel_hda_common,snd_soc_core,snd_hda_core,snd_pcm_dmaengine
snd 90112 33 snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek,snd_timer,snd_compress,thinkpad_acpi,snd_soc_core,snd_pcm,snd_rawmidi
3. 内核模块
$ dpkg -L linux-modules-$(uname -r) | grep snd
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq-dummy.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq-midi-emul.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq-midi-event.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq-midi.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq-virmidi.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/seq/snd-seq.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-compress.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-hrtimer.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-hwdep.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-pcm-dmaengine.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-pcm.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-rawmidi.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-seq-device.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd-timer.ko
/lib/modules/5.4.0-40-generic/kernel/sound/core/snd.ko
/lib/modules/5.4.0-40-generic/kernel/sound/drivers/pcsp/snd-pcsp.ko
/lib/modules/5.4.0-40-generic/kernel/sound/pci/snd-ens1370.ko
对比完全相同
我如何检查这些是否是我所需要的?
我如何检查这些是否与Intel在上述第2项中列出的相符?
我如何加载这些模块?
inxi
$ inxi -SA
System: Host: Hydrus1 Kernel: 5.4.0-40-generic x86_64 bits: 64 Desktop: Gnome 3.36.1 Distro: Ubuntu 20.04 LTS (Focal Fossa)
Audio: Device-1: Intel 6 Series/C200 Series Family High Definition Audio driver: N/A
Device-2: NVIDIA GF104 High Definition Audio driver: N/A
对比(还可以与this进行比较)
$ inxi -SA
System: Host: ViaLactea Kernel: 5.4.0-40-generic x86_64 bits: 64 Console: tty 0 Distro: Ubuntu 20.04 LTS (Focal Fossa)
Audio: Device-1: Intel Cannon Lake PCH cAVS driver: snd_hda_intel
Device-2: NVIDIA GP107GL High Definition Audio driver: snd_hda_intel
Sound Server: ALSA v: k5.4.0-40-generic
lspci
$ lspci -nnk | grep -A 1 音频
00:1b.0 音频设备 [0403]: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller [8086:1c20] (rev 04)
设备名称: 主板音频
子系统: Dell 6 Series/C200 Series Chipset Family High Definition Audio Controller [1028:04a4]
00:1c.0 PCI桥接器 [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 [8086:1c10] (rev b4)
--
01:00.1 音频设备 [0403]: NVIDIA Corporation GF104 High Definition Audio Controller [10de:0beb] (rev a1)
子系统: Dell GF104 High Definition Audio Controller [1028:04a4]
03:00.0 网络控制器 [0280]: Intel Corporation Centrino Ultimate-N 6300 [8086:422b] (rev 35)
对决
$ lspci -nnk | grep -n -A 4 Audio
49:00:1f.3 Audio device [0403]: Intel Corporation Cannon Lake PCH cAVS [8086:a348] (rev 10)
50- Subsystem: Lenovo Cannon Lake PCH cAVS [17aa:225f]
51- Kernel driver in use: snd_hda_intel
52- Kernel modules: snd_hda_intel, snd_sof_pci
53-00:1f.4 SMBus [0c05]: Intel Corporation Cannon Lake PCH SMBus Controller [8086:a323] (rev 10)
--
67:01:00.1 Audio device [0403]: NVIDIA Corporation GP107GL High Definition Audio Controller [10de:0fb9] (rev a1)
68- Kernel driver in use: snd_hda_intel
69- Kernel modules: snd_hda_intel
70-70:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS525A PCI Express Card Reader [10ec:525a] (rev 01)
71- Subsystem: Lenovo RTS525A PCI Express Card Reader [17aa:225f]
6. 系统(与完全相同的内核) ``` $ uname -a Linux Hydrus1 5.4.0-40-generic #44-Ubuntu SMP Tue Jun 23 00:01:04 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux ```
7. 测试声音 ``` $ aplay -l aplay: device_list:274: no soundcards found... ```
对决
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC285 Analog [ALC285 Analog]
Subdevices: 0/1
Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
...
8.
lshw
$ lshw -C multimedia
WARNING: you should run this program as super-user.
*-multimedia UNCLAIMED
description: Audio device
product: GF104 High Definition Audio Controller
vendor: NVIDIA Corporation
physical id: 0.1
bus info: pci@0000:01:00.1
version: a1
width: 32 bits
clock: 33MHz
capabilities: bus_master cap_list
configuration: latency=0
resources: memory:e0080000-e0083fff
*-multimedia UNCLAIMED
description: Audio device
product: 6 Series/C200 Series Chipset Family High Definition Audio Controller
vendor: Intel Corporation
physical id: 1b
bus info: pci@0000:00:1b.0
version: 04
width: 64 bits
clock: 33MHz
capabilities: bus_master cap_list
configuration: latency=0
resources: memory:e1e50000-e1e53fff
WARNING: output may be incomplete or inaccurate, you should run this program as super-user.
这里引用了(注意驱动程序)
$ sudo lshw -C multimedia
*-multimedia
description: Audio device
product: GP104 High Definition Audio Controller
vendor: NVIDIA Corporation
physical id: 0.1
bus info: pci@0000:01:00.1
version: a1
width: 32 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list
configuration: driver=snd_hda_intel latency=0
resources: irq:17 memory:f7080000-f7083fff
alsa
软件包$ dpkg -l | grep alsa ii alsa-base 1.0.25+dfsg-0ubuntu5 all ALSA驱动配置文件 ii alsa-tools-gui 1.1.7-1ubuntu1 amd64 针对特定硬件的基于GUI的ALSA实用程序 ii alsa-topology-conf 1.2.2-1 all ALSA拓扑配置文件 ii alsa-ucm-conf 1.2.2-1ubuntu0.1 all ALSA Use Case Manager配置文件 ii alsa-utils 1.2.2-1ubuntu1 amd64 用于配置和使用ALSA的实用程序 ii gstreamer1.0-alsa:amd64 1.16.2-4 amd64 ALSA的GStreamer插件 ii libsox-fmt-alsa:amd64 14.4.2+git20190427-2 amd64 SoX ALSA格式输入/输出库
如果我插入耳机也没有声音。
我没有要删除的
timidity-daemon
。尝试重新加载
$ sudo alsa force-reload [sudo] password for user1: 正在卸载 ALSA 声音驱动模块:(无已加载模块)。 正在加载 ALSA 声音驱动模块:(无需重新加载的模块)。
modprobe
$ grep intel /etc/modprobe.d/alsa-base.conf options snd-intel8x0m index=-2
(2)相关且可能有用的帖子
https://forums.linuxmint.com/viewtopic.php?t=221745
https://ubuntuforums.org/showthread.php?t=1684576
(3) 其他相关文章
https://www.alsa-project.org/wiki/Matrix:Module-hda-intel
https://askubuntu.com/a/1244118/226614 . 最近的帖子,被接受的答案。建议使用ppa
来修复。我不确定这样做会让情况变得更糟...
https://askubuntu.com/a/1249071/226614 . 最近的帖子。建议使用 sudo setfacl -m u:user1:rw /dev/snd/* 尝试了这个,没有帮助。
https://askubuntu.com/a/847954/226614 . 旧的帖子,被接受的答案。建议安装alsa-firmware-loaders
和alsa-base
。我不确定这是否仍然适用...
如何为Creative Labs Audigy2声卡安装缺失的固件?。这是一篇旧帖子,也提到UNCLAIMED
设备可能是由于固件问题引起的。
为什么问题在重新启动后出现?
升级后没有声音(18.04 -> 20.04),只有“虚拟输出”
在从Ubuntu 18.04 LTS升级到Ubuntu 20.04 LTS后,内置扬声器(音频)无法工作
linux-modules-kernel-version-generic
应该为您安装snd
驱动程序。看起来Intel Centrino Ultimate-N不再受支持,我不知道应该使用哪个驱动程序,但安装上述软件包可能会有所帮助。而SNDYBRDG(Sandy Bridge)与声音无关,实际上是英特尔在第二代Core处理器中使用的微架构的名称。 - Parsa Mousavi/proc
目录下的文件对应于正在运行在您系统上的进程,因此只有当Alsa有活动的播放进程(即正在播放声音)时,您才会看到/proc/aplay
。/dev
目录也是如此,它与设备相关联。 - Nate T