I have a laptop with Arch Linux.
It’s suspended with the systemctl suspend
.
The issue: after it’s wake up there is no sound.
From the information found during the investigation (see links below) the issue happens because of the NVIDIA drivers and isn’t specific to the Arch Linux – can happen with any other Linux distribution.
During googling first found the discussion here>>>.
Check devices after wake up with no sound:
[simterm]
$ pacmd list-cards 1 card(s) available. index: 1 name: <alsa_card.usb-046d_HD_Pro_Webcam_C920_6C52F41F-02> driver: <module-alsa-card.c> owner module: 7 properties: alsa.card = "2" alsa.card_name = "HD Pro Webcam C920" ...
[/simterm]
alsa.card_name = “HD Pro Webcam C920” – well, there is only my webcam found.
Restart the pulseaudio
daemon:
[simterm]
$ pulseaudio -k
[/simterm]
And the sound is back.
Check cards one more time:
[simterm]
$ pacmd list-cards | grep 'index:\|alsa.card_name' index: 0 alsa.card_name = "HDA NVidia" index: 1 alsa.card_name = "HD Pro Webcam C920" index: 2 alsa.card_name = "HDA Intel PCH"
[/simterm]
Check the pulseaudio
logs:
[simterm]
$ journalctl -b --user-unit pulseaudio -- Logs begin at Sat 2019-02-23 23:17:40 EET, end at Fri 2020-04-24 06:48:13 EEST. -- Apr 20 06:48:12 setevoy-arch-pc systemd[669]: Starting Sound Service... Apr 20 06:48:16 setevoy-arch-pc systemd[669]: Started Sound Service. Apr 24 06:31:57 setevoy-arch-pc pulseaudio[740]: W: [alsa-sink-ALC887-VD Analog] alsa-util.c: Could not recover alsa device from SUSPENDED state, trying to restart PCM Apr 24 06:31:57 setevoy-arch-pc pulseaudio[740]: E: [alsa-sink-ALC887-VD Analog] alsa-sink.c: Error opening PCM device front:1: No such file or directory Apr 24 06:31:57 setevoy-arch-pc pulseaudio[740]: W: [alsa-sink-HDMI 0] alsa-util.c: Could not recover alsa device from SUSPENDED state, trying to restart PCM Apr 24 06:31:57 setevoy-arch-pc pulseaudio[740]: E: [alsa-sink-HDMI 0] alsa-sink.c: Error opening PCM device hdmi:0: No such file or directory Apr 24 06:48:12 setevoy-arch-pc systemd[669]: pulseaudio.service: Succeeded. Apr 24 06:48:12 setevoy-arch-pc systemd[669]: Starting Sound Service... Apr 24 06:48:13 setevoy-arch-pc systemd[669]: Started Sound Service.
[/simterm]
Could not recover alsa device from SUSPENDED state – actually, this message led me to another discussion here>>>.
Add your user to the audio group:
[simterm]
$ sudo gpasswd -a setevoy audio Adding user setevoy to group audio
[/simterm]
And it’s the second week when it’s suspended/resumed each day and no issue presents now.
By the way, I found a great overview here – PulseAudio under the hood.