Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
pipewire-0.3.30-r1 and multi-user audio
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Thu Jul 15, 2021 1:52 am    Post subject: pipewire-0.3.30-r1 and multi-user audio Reply with quote

When pipewire-0.3.30-r1 hit stable it broke my 78.11.0esr stable firefox audio (running as a different user). I'm running an alsa system without pulseaudio. i enabled the new pipewire-alsa USE flag on the new pipewire-0.3.30-r1, but still nothing. Masking pipewire-0.3.30-r1 and downgrading to pipewire-0.3.22 returned firefox audio functionality.

Has anyone else run into this? I don't see anything relevant in bugs.gentoo.org. I'm thinking of filing a bug report but don't want to do that if I'm just overlooking something.


Last edited by radio_flyer on Fri Jul 16, 2021 6:16 am; edited 1 time in total
Back to top
View user's profile Send private message
grumblebear
Apprentice
Apprentice


Joined: 26 Feb 2008
Posts: 202

PostPosted: Thu Jul 15, 2021 9:19 am    Post subject: Reply with quote

Try pipewire-0.3.31. I remember an unsuccessful attempt with pipewire-0.3.30 myself. Unfortunately just that version has been stabilised.
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Thu Jul 15, 2021 4:46 pm    Post subject: Reply with quote

Thanks. I just tried upgrading to that version but it has the same problem as 0.3.30-r1. I went ahead and filed a bug report: https://bugs.gentoo.org/802300
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Fri Jul 16, 2021 6:34 am    Post subject: Reply with quote

OK, now I see what's going on. I've changed the subject title of this thread to match the actual issue and closed the bug report.

With pipewire-0.3.30 and above, the default configuration changed such that users in the audio group are no longer automatically 'connected' to pipewire. Instead, /usr/libexec/pipewire-launcher fires up pipewire from /etc/xdg/autostart/pipewire.desktop. In other words, when I log into KDE the user I log in as can run audio applications. In fact, multiple audio applications can run and are mixed to the outputs from the desktop.

However, I run firefox from a konsole window after su 'ing to a different user with very few privileges. This user belongs to the audio group, but because this new version of pipewire seems to attach itself to the WM user there is no audio device available to the konsole window user. Hence, when I run firefox from that konsole there is no audio device for firefox. If I run /usr/libexec/pipewire-launcher & in the konsole window after su 'ing to this user, I can then access the audio devices and firefox is able to play audio. However, it is not possible for both users (eg firefox and another audio application running under KDE) to play audio simultaneously. This was possible with the previous pipewire/alsa configuration.

Unfortunately, I don't see any configuration options available in the pipewire configuration files to enable audio for multiple users at system startup. An internet search turned up nothing useful. If anyone else has run into similar issues with pipewire and found a solution, please share.
Back to top
View user's profile Send private message
Small_Penguin
Tux's lil' helper
Tux's lil' helper


Joined: 27 May 2005
Posts: 140

PostPosted: Mon Jul 19, 2021 3:28 pm    Post subject: Reply with quote

I also wonder whether pipewire has better support for multi-user setups. I'd like to use it on my family pc, and till now I've stayed with alsa for this very reason, because that simply works.
pulseaudio could do it somehow, but it is not an officially supported way. There is a similar post in the arch forums: https://bbs.archlinux.org/viewtopic.php?id=265878
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Mon Jul 19, 2021 5:05 pm    Post subject: Reply with quote

I found that page as well. There's also this page: https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/1135
which discusses some of the Gentoo issues.

Clearly pipewire is under heavy development and changes regularly as a "work in process". Unfortunately, it's also the only solution for those of us who run OpenRC and avoid systemd, but also prefer firefox which is now pulseaudio-only. I like the end goal of pipewire being the audio/visual server replacement for all of alsa, pulse, jack and gstreamer, but it looks like it's going to be a bumpy ride.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Jul 19, 2021 5:13 pm    Post subject: Reply with quote

radio_flyer wrote:
... but also prefer firefox which is now pulseaudio-only.

You know something I don't. What version of Firefox you are talking about? I have 90 and it makes sound with plain ALSA.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Tue Jul 20, 2021 4:55 am    Post subject: Reply with quote

Stable 78.11.0esr. You're not even using apulse? I moved to pipewire because firefox completely broke on my alsa-only setup a while back, and everything I read (including https://wiki.gentoo.org/wiki/Firefox) said I needed some sort of pulseaudio-like setup.
Back to top
View user's profile Send private message
krumpf
Apprentice
Apprentice


Joined: 15 Jul 2018
Posts: 167

PostPosted: Tue Jul 20, 2021 6:32 am    Post subject: Reply with quote

I'm using firefox esr78 on a pure alsa system (without apulse) and it works.

Did you change the samplerate in your asoundrc ?
I once tried to change it from 48000 (default) to 96000, and a few apps -firefox included- would stop playing sounds.
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Tue Jul 20, 2021 8:53 pm    Post subject: Reply with quote

Nope. Don't even have an asoundrc. It was a basic ALSA default setup. Interesting reports. I'll have to try going back to a simple ALSA-only setup and see how if it works for me now. That would certainly be my preference, since pipewire seems to be in a broken state of flux at the moment.
Back to top
View user's profile Send private message
piedar
Tux's lil' helper
Tux's lil' helper


Joined: 09 Aug 2010
Posts: 82

PostPosted: Fri Jan 21, 2022 5:46 pm    Post subject: Reply with quote

This happens because pipewire listens at ${XDG_RUNTIME_DIR}/pulse/native by default. You could share this directory between the users, but that's not particularly secure. Fortunately pipewire can also listen on a TCP port.
Copy /usr/share/pipewire/pipewire-pulse.conf to ~/.config/pipewire/ then add "tcp:127.0.0.1:4713" to the server.address array after "unix:native". Finally, add PULSE_SERVER=tcp:127.0.0.1:4713 to the environment for the secondary user.
Back to top
View user's profile Send private message
mega_flow
Tux's lil' helper
Tux's lil' helper


Joined: 26 Jun 2016
Posts: 84
Location: Belgium

PostPosted: Fri Jan 21, 2022 11:00 pm    Post subject: Reply with quote

If u use systemD, can u try with root
I also believe pipewire need acces to dbus on user level
Code:
systemctl --global enable --now pipewire.socket
systemctl --global enable --now pipewire.service

_________________
Intel(R) Core(TM) i7-10875H - GeForce GTX 1660 Ti Mobile
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21431

PostPosted: Sat Jan 22, 2022 2:01 am    Post subject: Reply with quote

mega_flow wrote:
If u use systemD
OP does not use systemd:
radio_flyer wrote:
I'm running OpenRC also, as I'm not a big fan of the systemd philosophy.
Back to top
View user's profile Send private message
radio_flyer
Guru
Guru


Joined: 04 Nov 2004
Posts: 317
Location: Northern California

PostPosted: Sat Jan 22, 2022 5:11 pm    Post subject: Reply with quote

I managed to revert back successfully to an alsa-only setup as krumpf suggested and threw pipewire out. Firefox seems to work OK without it. Thanks piedar for the TCP port suggestion. If I need to fire it back up again someday I'll give that a try.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum