Pulse audio not working unless root
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Pulse audio not working unless root
I recently started having problems with my audio. I tracked down the issue after some work to a permissions problem.
If I try to open pulse audio using pavucontrol it opens but never establishes a connection with the following issue shm_open() failed: No such file or directory
This works fine if I do sudo pavucontrol.
As a consequence whenever I use a media player it has no sound. Strangely enough sound works fine through my browsers.
I tried adding my user to groups 'audio, pulse, and pulse-access' but that didnt help. After some searching online I tried modifying /etc/fstab and /etc/pulse/client.conf to no avail. I also looked at my /run/user folder and my user owns the pulse files there. I'm at a loss as to how to solve this.
If I try to open pulse audio using pavucontrol it opens but never establishes a connection with the following issue shm_open() failed: No such file or directory
This works fine if I do sudo pavucontrol.
As a consequence whenever I use a media player it has no sound. Strangely enough sound works fine through my browsers.
I tried adding my user to groups 'audio, pulse, and pulse-access' but that didnt help. After some searching online I tried modifying /etc/fstab and /etc/pulse/client.conf to no avail. I also looked at my /run/user folder and my user owns the pulse files there. I'm at a loss as to how to solve this.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 3 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Re: Pulse audio not working unless root
Are you perhaps using firejail?
Re: Pulse audio not working unless root
That's probably how you broke it - now root own your pulse files.BigAngry wrote:This works fine if I do sudo pavucontrol.
If this command returns files, take ownership of them:
Code: Select all
find $HOME ! -user $USER
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Your data and OS are backed up....right?
Re: Pulse audio not working unless root
There were quite a few files returned by that command, among them was the pulse ini. I didnt realize running sudo would cause ownership to change, thats seems a bit odd. I took ownership and after a restart it started working again. Thanks!Flemur wrote:That's probably how you broke it - now root own your pulse files.BigAngry wrote:This works fine if I do sudo pavucontrol.
If this command returns files, take ownership of them:Code: Select all
find $HOME ! -user $USER
Re: Pulse audio not working unless root
I think it's sort-of a bug...because the problems it causes show up here!BigAngry wrote: I didnt realize running sudo would cause ownership to change, thats seems a bit odd.
When you run GUI programs use "gksudo" (or "ksudo"[?] in KDE), like
Code: Select all
gksudo pavucontrol
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Your data and OS are backed up....right?
Re: Pulse audio not working unless root
Ok for some reason it stopped working again, and this time nothing shows up from 'find $HOME ! -user $USER'
This is a bit perplexing.
This is a bit perplexing.
Re: Pulse audio not working unless root
I've messed around with it some more but cant seem to figure it out. Any suggestions?
Re: Pulse audio not working unless root
Well, I removed pulseaudio! (Although that can cause problems depending on your HW and what you do with it, so it's not officially recommended...and isn't possible with Cinnamon. The only thing I used pulseaudio for was to record "what you hear", which I can do without it with a different sound card. Though now firefox requires it...sigh...so use old FF version.)BigAngry wrote:I've messed around with it some more but cant seem to figure it out. Any suggestions?
Anyway, another typical pulseaudio fix/hack is to remove its files under your $HOME.
Code: Select all
find ~ -iname "*pulse*
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Your data and OS are backed up....right?
Re: Pulse audio not working unless root
Removing pulseaudio is not only not recommended, for good reason, it's unnecessary. Try a read of this by a Canonical dev ...
http://voices.canonical.com/david.henni ... our-audio/
http://voices.canonical.com/david.henni ... our-audio/
For every complex problem there is an answer that is clear, simple, and wrong - H. L. Mencken
Re: Pulse audio not working unless root
Alright after digging around some more I figured out the root cause of the issue. Seems to be that whenever I launch firefox with firejail, it prevents pulse from creating new files in /dev/shm and deletes whatever files were present on boot.
I believe its this exact issue referenced here https://bugs.freedesktop.org/show_bug.cgi?id=92141. Towards the bottom they specify that in pulse 9 and 10 that the issue was fixed. I see that the newest version of pulse is 11. However, mine is 8. I looked into updating it to 11, but that seems to be a daunting task.
Could someone point me in the right direction as for a proper guide on how to do the upgrade, or how to configure firejail not to mess my stuff up?
I believe its this exact issue referenced here https://bugs.freedesktop.org/show_bug.cgi?id=92141. Towards the bottom they specify that in pulse 9 and 10 that the issue was fixed. I see that the newest version of pulse is 11. However, mine is 8. I looked into updating it to 11, but that seems to be a daunting task.
Could someone point me in the right direction as for a proper guide on how to do the upgrade, or how to configure firejail not to mess my stuff up?
Re: Pulse audio not working unless root
Try this workaround.