Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: pipewire conflict with kdeconnect dependency pulseaudio-qt  (Read 1489 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

pipewire conflict with kdeconnect dependency pulseaudio-qt

I'm using Artix plasma openrc iso which comes with pulseaudio default. I uninstalled pulse-audio and installed pipewire. This works unless I install kdeconnect, which has dependency of pulseaudio-qt.
If pulseaudio-qt is installed then pipewire intermittently fails to start on login. Sometimes my sound works, sometimes it doesn't. When it doesn't, it gives this error:

Code: [Select]
pulse-server.c: 5538 pw_protocol_pulse_new()] 0x55609cdd3c00: no servers could be started: Address already in use

I looked online and per that advice went to etc/pulse/client.conf and made autospawn = no . This had no effect.

Here is a terminal output from my system:
Code: [Select]
$ pacman -Qe | grep pulse
pipewire-pulse 1:0.3.80-1
$ pacman -Q | grep pulse
lib32-libpulse 16.1-6
libpulse 16.1-6
pipewire-pulse 1:0.3.80-1
pulseaudio-qt 1.3-1


Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #2
If pulseaudio-qt is installed then pipewire intermittently fails to start on boot. Sometimes my sound works, sometimes it doesn't.

Try starting pipewire when you start the desktop rather than at boot.
https://wiki.artixlinux.org/Site/PipewireInsteadPulseaudio
I misworded my initial post. Pipewire is started at desktop. it starts fine if kdeconnect is not installed. if kdeconnect is installed it adds  pulseaudio-qt which prevents pipewire from running after I restart the computer.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #3
For the record I have a plasma openc install and do use kdeconnect. I don't currently have the issue with pipewire you describe.
Though I frequently do have various issues with pipewire, or at least sound. They come, they go, they sometimes come back again. And it's rare that I can do much more than just work around them until at the point of some future update they just disappear.
Latest was sound on the master channel being muted at every login. All the settings seemed right for it not to be muted. I gave up looking at it and just unmuted every login. Then at some point it just started working properly again.

Can you reproduce this pulseaudio-qt caused problem ?
As in if you remove kdeconnect and dependencies does pipewire work 100% of the time and then stop working as such, as soon as you install kdeconnect again ?

Because maybe it's just a coincidence and shitewire (my pet name for it) is just being shitewire ?

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #4
For the record I have a plasma openc install and do use kdeconnect. I don't currently have the issue with pipewire you describe.
Though I frequently do have various issues with pipewire, or at least sound. They come, they go, they sometimes come back again. And it's rare that I can do much more than just work around them until at the point of some future update they just disappear.
Latest was sound on the master channel being muted at every login. All the settings seemed right for it not to be muted. I gave up looking at it and just unmuted every login. Then at some point it just started working properly again.

Can you reproduce this pulseaudio-qt caused problem ?
As in if you remove kdeconnect and dependencies does pipewire work 100% of the time and then stop working as such, as soon as you install kdeconnect again ?

Because maybe it's just a coincidence and shitewire (my pet name for it) is just being shitewire ?

yes I can 100% reproduce this, when kdeconnect is installed pipewire doesn't start. If kdeconnect or pulseaudio-qt is removed it starts working again on reboot.

Also I had similar problems with pulseaudio. I have 5.1CH output and it would often balance the speakers to random values.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #5
How exactly are you starting pipewire ?
Me (in ~/.xintrc)
Code: [Select]
/usr/bin/pipewire &
/usr/bin/pipewire-pulse &
#/usr/bin/pipewire-media-session &
/usr/bin/wireplumber &
Which one generates your error ?

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #6
Hello,

I have been using alsa only for several years.
I removed all pulse packets except libpulse and libcanberra.

I use alsa and the nice and very practical qastools mixer on different pc:
https://forum.artixlinux.org/index.php/topic,4318.msg27848.html#msg27848

Note: I don't play games and don't use wine or steam.
But I have sound in all my apps.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #7
How exactly are you starting pipewire ?
Me (in ~/.xintrc)
Code: [Select]
/usr/bin/pipewire &
/usr/bin/pipewire-pulse &
#/usr/bin/pipewire-media-session &
/usr/bin/wireplumber &
Which one generates your error ?

I'm starting them using Autostart under Startup and Shutdown. I'm on openrc/plasma

In the event they don't startup (when kdeconnect is installed), this is the output they give:

Code: [Select]
$ wireplumber
[0:14:11.613691701] [9478] ERROR IPAModule ipa_module.cpp:172 Symbol ipaModuleInfo not found
[0:14:11.613704691] [9478] ERROR IPAModule ipa_module.cpp:292 v4l2-compat.so: IPA module has no valid info
[0:14:11.613728926] [9478]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
W 20:29:49.087836 m-portal-permissio ../wireplumber/modules/module-portal-permissionstore.c:63:wp_portal_permissionstore_plugin_lookup: <WpPortalPermissionStorePlugin:0x558ec3364a30> Failed to call Lookup: GDBus.Error:org.freedesktop.portal.Error.NotFound: No entry for camera

Code: [Select]
$ pipewire
[E][00895.807479] mod.protocol-native | [module-protocol-:  714 lock_socket()] server 0x55973aa79c50: unable to lock lockfile '/run/user/1000/pipewire-0.lock': Resource temporarily unavailable (maybe another daemon is running)
[E][00895.807555] pw.conf      | [          conf.c:  573 load_module()] 0x55973aa326d0: could not load mandatory module "libpipewire-module-protocol-native": Resource temporarily unavailable
[E][00895.808113] default      | [      pipewire.c:  105 main()] failed to create context: Resource temporarily unavailable


Code: [Select]
$ pipewire-pulse
[W][00900.633272] mod.protocol-pulse | [        server.c:  589 start_unix_server()] server 0x55f4e78093b0: socket '/run/user/1000/pulse/native' is in use
[W][00900.633315] mod.protocol-pulse | [        server.c: 1021 servers_create_and_start()] pulse-server 0x55f4e7808c00: failed to start server on 'unix:/run/user/1000/pulse/native': Address already in use
[E][00900.633321] mod.protocol-pulse | [  pulse-server.c: 5538 pw_protocol_pulse_new()] 0x55f4e7808c00: no servers could be started: Address already in use
[E][00900.633363] pw.conf      | [          conf.c:  573 load_module()] 0x55f4e77b36d0: could not load mandatory module "libpipewire-module-protocol-pulse": Address already in use
[E][00900.633576] default      | [      pipewire.c:  105 main()] failed to create context: Address already in use

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #8
That's still not stating exactly how you start them. Just a bit less vaguely.

Clearly from the errors pipewire and friends believe the addresses / sockets are in use.

Have you checked after a failed sound start if any of the three processes are running? I expect they or at least one are.

Have you tried disabling the autostart of the three programs, rebooting, and then starting them manually in a terminal. Just to see what happens.  Because it seems the errors you are collecting are from when you run the programs again after no sound. But they are already running. More useful might be any errors from the first run. Where they start, at least in part, but there is no sound.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #9
That's still not stating exactly how you start them. Just a bit less vaguely.

Clearly from the errors pipewire and friends believe the addresses / sockets are in use.

Have you checked after a failed sound start if any of the three processes are running? I expect they or at least one are.

Have you tried disabling the autostart of the three programs, rebooting, and then starting them manually in a terminal. Just to see what happens.  Because it seems the errors you a collecting are from when you run the programs again after no sound. But they are already running. More useful might be any errors from the first run. Where they start, at least in part, but there is no sound.

I start them with Autostart. Here's a picture.



The processes are running. But they can't work. Because pulseaudio stole pipewire's port. I'll test later today what it says if they are not auto started.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #10
You have pipewire-media-session as well as wireplumber which seems off. Last I checked it was not possible to have have both installed without trickery.

You have no control over the order they start. Which I believe is important. And could be why pulse is stealing pipewires port ?
Delete them all from autostart and autostart a script instead (make it executable) as described on the wiki page I linked earlier.
Code: [Select]
#!/bin/sh
/usr/bin/pipewire &
/usr/bin/pipewire-pulse &
/usr/bin/wireplumber &

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #11
You have pipewire-media-session as well as wireplumber which seems off. Last I checked it was not possible to have have both installed without trickery.

You have no control over the order they start. Which I believe is important. And could be why pulse is stealing pipewires port ?
Delete them all from autostart and autostart a script instead (make it executable) as described on the wiki page I linked earlier.
Code: [Select]
#!/bin/sh
/usr/bin/pipewire &
/usr/bin/pipewire-pulse &
/usr/bin/wireplumber &

In regards to point 1, I had pipewire-media-session installed but when I read your wiki it noted wireplumber so I installed wireplumber and it removed pipewire-media-session. I didn't delete the startup entry.

In regards to point 2,

xinit:
I did
Code: [Select]
cp /etc/X11/xinit/xinitrc ~/.xinitrc
Then i edit ~/.xinitrc to have this:

Nothing started up :(

stratup script:
I made a file ~/.startup
I made it executable
I put in what the wiki says
I added it to autostart on user login

Nothing started up :(
edit: upon reboot, I look in autostart, and the .startup entry I added is no longer there.
edit2: I removed the . from the name and added ~/startup to autostart login script. Its still there after reboot, but nothing actually started.

Am I doing something wrong?

If I run that manually in terminal, it gives some errors but starts working:
Code: [Select]
~$  /usr/bin/pipewire & /usr/bin/pipewire-pulse & /usr/bin/wireplumber
[1] 6776
[2] 6777
[0:09:55.915971259] [6778] ERROR IPAModule ipa_module.cpp:172 Symbol ipaModuleInfo not found
[0:09:55.915986554] [6778] ERROR IPAModule ipa_module.cpp:292 v4l2-compat.so: IPA module has no valid info
[0:09:55.916015259] [6778]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
M 02:54:46.627575    m-lua-scripting ../wireplumber/modules/module-lua-scripting/api/api.c:376:object_activate_done: <WpSiAudioAdapter:0x55e6068b7b70> Object activation aborted: proxy destroyed
M 02:54:46.627620 script/create-item create-item.lua:80:chunk: <WpSiAudioAdapter:0x55e6068b7b70> failed to activate item: Object activation aborted: proxy destroyed

another edit:

tried adding that as a openrc service in /etc/init.d and then adding that service to run at default level via openrc. did not do anything.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #12
Must be I guess?

~/.xinitrc is generally only run if starting X (the desktop) with startx, or xinit. (But there maybe exceptions)
Even if you were using a method of starting X which called ~/.xinitrc what you show would not have worked because you copied the system one so it would have paused execution at
Code: [Select]
exec xterm -geometry 80x66+0+0 -name login
until X was closed.
Don't concern yourself but it's wrong.

If using a display manager such as sddm you can use ~/.xprofile to serve the same purpose
https://wiki.archlinux.org/title/Xprofile explains it a litte but ignore the part "1.1 Sourcing xprofile from a session started with xinit". To me it just adds unnecessary confusion.

When you use the KDE GUI to create your autostart it will create a file WHAT_YOU_CALLED_IT.desktop in ~/.config/autostart
What does this file contain ?

Show ls -al ~/.config/autostart

It might be worth just trying the ~/.xprofile method?
Or try deleting the autostart entry. Reboot . Run the script you created in a terminal.
Code: [Select]
sh ~/.startup

If pipewire starts and works there was something wrong with the autostart entry. If it doesn't there is something wrong with the script.

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #13
Am I doing something wrong?
Must be I guess?

~/.xinitrc is generally only run if starting X (the desktop) with startx, or xinit. (But there maybe exceptions)
Even if you were using a method of starting X which called ~/.xinitrc what you show would not have worked because you copied the system one so it would have paused execution at
Code: [Select]
exec xterm -geometry 80x66+0+0 -name login
until X was closed.
Don't concern yourself but it's wrong.

If using a display manager such as sddm you can use ~/.xprofile to serve the same purpose
https://wiki.archlinux.org/title/Xprofile explains it a litte but ignore the part "1.1 Sourcing xprofile from a session started with xinit". To me it just adds unnecessary confusion.

When you use the KDE GUI to create your autostart it will create a file WHAT_YOU_CALLED_IT.desktop in ~/.config/autostart
What does this file contain ?

Show ls -al ~/.config/autostart

It might be worth just trying the ~/.xprofile method?
Or try deleting the autostart entry. Reboot . Run the script you created in a terminal.
Code: [Select]
sh ~/.startup

If pipewire starts and works there was something wrong with the autostart entry. If it doesn't there is something wrong with the script.


I edited /etc/x11/xinit/xinitrc and added that code there. Nothing started up.

Here is how the folder looks with my regular autostart entries:
Code: [Select]
$ ls -al ~/.config/autostart
total 36
drwxr-xr-x   2 user user  4096 Sep 30 13:57  .
drwxr-xr-x 144 user user 12288 Sep 30 13:57  ..
-rw-r--r--   1 user user   244 Jun  4 15:00  com.nextcloud.desktopclient.nextcloud.desktop
-rw-r--r--   1 user user  1661 Jul 11 02:37  lxpolkit.desktop
-rw-------   1 user user   110 Sep 30 03:18 'PipeWire Media System.desktop'
-rw-------   1 user user   109 Sep 30 03:19  pipewire-pulse.desktop
-rw-------   1 user user   103 Sep 30 03:19  wireplumber.desktop

Here is how it looks with startup script:

Code: [Select]
$ ls -al ~/.config/autostart
total 28
drwxr-xr-x   2 user user  4096 Sep 30 14:02 .
drwxr-xr-x 144 user user 12288 Sep 30 14:07 ..
-rw-r--r--   1 user user   244 Jun  4 15:00 com.nextcloud.desktopclient.nextcloud.desktop
-rw-r--r--   1 user user  1661 Jul 11 02:37 lxpolkit.desktop
-rw-------   1 user user   117 Sep 30 14:02 startup.desktop

Here is what happens if I run the startup script in terminal (it works):
Code: [Select]
$ sh ~/startup
[0:01:06.525906760] [4741] ERROR IPAModule ipa_module.cpp:172 Symbol ipaModuleInfo not found
[0:01:06.525921985] [4741] ERROR IPAModule ipa_module.cpp:292 v4l2-compat.so: IPA module has no valid info
[0:01:06.525950131] [4741]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
M 14:05:34.532637    m-lua-scripting ../wireplumber/modules/module-lua-scripting/api/api.c:376:object_activate_done: <WpSiAudioAdapter:0x55e6cefbc960> Object activation aborted: proxy destroyed
M 14:05:34.532683 script/create-item create-item.lua:80:chunk: <WpSiAudioAdapter:0x55e6cefbc960> failed to activate item: Object activation aborted: proxy destroyed

Made ~/.xprofile with this:

Code: [Select]
 
 /usr/bin/pipewire &
 /usr/bin/pipewire-pulse &
 /usr/bin/wireplumber

at reboot, this did nothing.

 

Re: pipewire conflict with kdeconnect dependency pulseaudio-qt

Reply #14
I installed a bunch more pipewire stuff from world repo and added artix-pipewire-launcher to startup and it has worked for the last 3 boots.