Linux Problems with audio
#1
I use my pc mainly with kodi. So, when i boot up, arch linux starts kodi standalone, with kodi user, that launches the kodi interface without having to log in another specific user.
The problem I've been facing these last month is that the audio does not work most of the times and I seem to solve it rebooting. This has been happening 1 out of ten times I boot, I. E. But lately, it's very common to have to reboot 4 or 5 times in order to get the audio working.
Now, the problem might be that I also have kde installed, just in case I need to use the computer for anything other than playing media, so, if i need to use kde, I would go to any free console with ctr+alt+FX combination, login as a normal user and run: systemctl stop kodi && startx
This would log me in to kde and let me do whatever I want.
I discovered I can run pavucontrol and there, I can see the different HDMI outputs. It seems like the correct output is hdmi 2 but by default, hdmi 1 gets selected, which appears as "unplugged ". Once I run pavucontrol, everything works fine again. I can log out from kde and run kodi again and boom! Let there be sound!
How can I set this to choose the correct pulseaudio configuration by default? Maybe there is some other audio subsystem in conflict? I'm a bit lost here and the pulseaudio wiki seems overwhelming.
I've read on arch forums this might be a bug happening in kodi, and I'd like to help debugging it: Just tell me what info is needed Smile
Any help would be nice!
Reply
#2
Debug Log is needed from a non working start. If you use pulseaudio 8 - be aware of this bug from the wiki:

Quote:Audio devices are disappearing with pulseaudio 8.0 (Ubuntu 16.04) especially while running kodi and while using Adjust Refreshrate to match video. This is an issue with the module-switch-on-port-available module and will be fixed with pulseaudio 9.0, the fix sadly won't probably make it into Ubuntu 16.04. As a workaround please disable that feature by editing /etc/pulse/default.pa and commenting or removing load-module module-switch-on-port-available and reboot the system.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#3
(2016-06-27, 09:47)fritsch Wrote: Debug Log is needed from a non working start. If you use pulseaudio 8 - be aware of this bug from the wiki:

Quote:Audio devices are disappearing with pulseaudio 8.0 (Ubuntu 16.04) especially while running kodi and while using Adjust Refreshrate to match video. This is an issue with the module-switch-on-port-available module and will be fixed with pulseaudio 9.0, the fix sadly won't probably make it into Ubuntu 16.04. As a workaround please disable that feature by editing /etc/pulse/default.pa and commenting or removing load-module module-switch-on-port-available and reboot the system.

Thanks, I will try this fix and report back when I'm back at home. Sorry for not researching a bit more, but the info is sometimes overwhelming and I wasn't even sure where the problem was.
Thank you very much for your help.
Reply
#4
The workaround didn't work. I'm thinking maybe manually installing pulseaudio 9. On arch we've got it on testing, so it should be updated soon, I guess. You say this fixes the problem?
I might try and roll back If I encounter some unexpected issue...
Reply
#5
-> Try LibreELEC from USB stick, that rules out custom made distribution setup errors.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#6
(2016-06-27, 23:34)fritsch Wrote: -> Try LibreELEC from USB stick, that rules out custom made distribution setup errors.

Will do and report later today. Thanks for the suggestion.

I might say, I've been using xbmc/kodi for quite some years already wit barely the same setup. Before, with my old graphics card, I used to have to edito some alsa files so the hdmi output was selected correclty, but this problem vanished like 2 years ago or so. 9 months ago, I bought a new pc, with a different graphics card (nVidia GTX970) and didn't have many issues after I set it up the first time: This problem has been progressive until a month ago or so when it became unbearable.....
Let's see if I find a solution: Yesterday, it took me 6 reboots in order to watch GoT
Reply
#7
You use pulseaudio now, which seems the big difference to me. And your startup seems to have a race. As you refuse to post your Debug Log and cannot help you further.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#8
(2016-06-28, 08:14)fritsch Wrote: You use pulseaudio now, which seems the big difference to me. And your startup seems to have a race. As you refuse to post your Debug Log and cannot help you further.

Sorry, it's not that I refuse, but that I spend most of the day at my workplace and didn't have much time to troubleshoot the PC. I'll try to paste a debug log tonight.
Thanks!
Reply
#9
(2016-06-28, 08:14)fritsch Wrote: You use pulseaudio now, which seems the big difference to me. And your startup seems to have a race. As you refuse to post your Debug Log and cannot help you further.

Here you have a log: http://pastebin.com/y2d8TbQ4


BTW: Strange thing happened: On startup, there wa sno sound, but while i was enabling the plugin and copying the log file, the sound suddenly started working again. Just where it says "19:04:09 T:139793065555712 NOTICE: PulseAudio: Opened device Default in pcm mode with Buffersize 150 ms" , line 182 of the log.

HuhHuhHuhHuhHuh


Thansk for your support


Forgot to mention i tried upgrading to pulseaudio 9 with the same issues,
Reply
#10
You use the default output device from PA which is opened correctly. Though _which_ the default device is, kodi has no influence - as this is totally a PA related. Most likely something in your system changes the default device behind your back. At start kodi sees two devices (default one + GM204 High Definition Audio Controller Digital Stereo (HDMI))

Which one do you use? HDMI output?
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#11
(2016-06-28, 20:36)fritsch Wrote: You use the default output device from PA which is opened correctly. Though _which_ the default device is, kodi has no influence - as this is totally a PA related. Most likely something in your system changes the default device behind your back. At start kodi sees two devices (default one + GM204 High Definition Audio Controller Digital Stereo (HDMI))

Which one do you use? HDMI output?

Yes, I use the hdmi output of the gtx 970.
Reply
#12
As we see and find the device right at the start - something else makes it ready afterwards. There is nothing I can do in that regard.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#13
(2016-06-28, 21:37)fritsch Wrote: As we see and find the device right at the start - something else makes it ready afterwards. There is nothing I can do in that regard.

I'm kind of lost now. I see you mean kodi is not to blame... What would you suggest me to do? Maybe take a look at pulseaudio? Try to shift to alsa alone? Thanks!
Reply
#14
Sorry - this is something your distribution needs to solve for you. Kodi needs a fully up and running environment before it can be started. Delay the kodi start by 60 seconds and see what happens (while not delaying the other startup stuff).
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#15
(2016-06-29, 09:48)fritsch Wrote: Sorry - this is something your distribution needs to solve for you. Kodi needs a fully up and running environment before it can be started. Delay the kodi start by 60 seconds and see what happens (while not delaying the other startup stuff).

Thanks for your help troubleshooting this issue.
Reply

Logout Mark Read Team Forum Stats Members Help
Problems with audio0