Skip to main content
Topic: Pipewire Audio only works after restarting X (Read 529 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Pipewire Audio only works after restarting X

So I recently installed Artix with openrc and since the beginning I've had this problem where I dont hear any sound when starting my dwm session (through xinit). When I quit X and startx again, however, it works. From my .xinitrc I am starting Pipewire like this, as written in the Artix wiki page about Pipewire:
Code: [Select]
/usr/bin/pipewire &
/usr/bin/pipewire-alsa &
/usr/bin/pipewire-jack &
/usr/bin/pipewire-pulse &
/usr/bin/wireplumber &
exec dwm
Any ideas how I can make it work so that I hear sound on the first login too? Thanks in advance:))

Re: Pipewire Audio only works after restarting X

Reply #1
Any ideas how I can make it work so that I hear sound on the first login too?

I would implement not the second but the first suggestion.

See:
https://wiki.archlinux.org/title/Display_manager#Autostarting
https://man.archlinux.org/man/sleep.1

Side note:
Openbox has ~/.config/openbox/autostart <<< you should mention that in the article.

Example:
Code: [Select]
(sleep 7s && ~/.local/bin/pipewire.sh) &
"Wer alles kann, macht nichts richtig"

Artix USE="runit openrc slim openbox lxde gtk2 qt4 qt5 qt6 conky
-gtk3 -gtk4 -adwaita{cursors,themes,icons} -gnome3 -kde -plasma -wayland "

Re: Pipewire Audio only works after restarting X

Reply #2
Thanks for the answer. However, I found out that it had something to do with dbus not being launched yet (although it is added to runlevel default), but after I installed and added the bluez-openrc service, it worked too

Re: Pipewire Audio only works after restarting X

Reply #3
However, I found out that it had something to do with dbus not being launched yet (although it is added to runlevel default)
The one in runlevel default is the 'system' dbus. You need a 'user' dbus as well. 
This is how KDE is started in my .xinitrc
Code: [Select]
exec dbus-launch --exit-with-session startplasma-x11
I imagine you could do the same with dwm ?