Can't get the pulse server to run

Hi,

I would like to set up a Pulse server on my Fedora 36 system so that a second desktop user can access it.
To do this, I copied the file pipewire-pulse to the directory of the first user martin and made adjustments in it.

[martin@fc36> ~]$ mkdir ~/.config/pipewire/; cp /usr/share/pipewirepipewire-pulse.conf ~/.config/pipewire/

pulse.properties = {
    # the addresses this server listens on
    server.address = [
        "unix:native"
        "tcp:4713"                         # IPv4 and IPv6 on all addresses
    ]

I have added the following to ~/.bashrc so that the environment variable PULSE_SERVER are available.

export PULSE_SERVER=tcp:127.0.0.1:4713

after the restart the environment variable is set, but

[martin@fc36 ~]$ env |grep PULSE
PULSE_SERVER=tcp:127.0.0.1:4713

but pactl give me an error:

[martin@fc36 ~]$ pactl info
Connection failure: Connection refused

what have I done wrong ?
PS: Pulse server installation with Fedora 36 on a Vmware guest system works

Regards
Martin

1 Like

You should not have copied that into the users config.
Each user should be able to access the audio and pipewire will write its own new config file for that user when they first start up audio. Copying things between users in that way is sure to leave something that may point in the wrong way instead of cleanly configuring it for the new user.

Knowing a bit more about the setup would help.
Are you running a remote server to provide media for playback?
Are you both using the same PC for access to the media?
Are you on 2 different PCs and both want access at the same time?
Is the media on your PC and you want to allow a user on another PC to have access?

??

both users are on the same PC

User 1: martin
User 2: vdr
/etc/passwd
martin:x:1000:1000:Martin Gansser:/home/martin:/bin/bash
vdr:x:980:39:Video Disk Recorder:/var/lib/vdr/data:/sbin/nologin

User 2 (vdr) should be able to access the running Pulse server.

1 Like

The user vdr is the user that runs a system tool and should require NO CHANGES in its home directory to do its job.

Have you tried the command groups vdr to see what groups that user is a member of? Have you compared that to the output of groups to see what groups you may be a member of that may apply to the vdr user? Have you done any other trouble shooting or did you just start arbitrarily changing configs for the system tools?

On my system I have full access to all the audio tools by being a member of the ‘audio’ group, though I doubt that is needed for vdr.

1 Like

The user vdr is a member of the groups video,cdrom, dialout and audio

[martin@fc36 ~]$ groups vdr
vdr : video cdrom dialout audio

I certainly did not make any arbitrary configurations.
In the home directory of user vdr I created a client.conf with the following content:

[martin@fc36 ~]$ cat -v /var/lib/vdr/data/.pulse/client.conf 
autospawn = no
default-server = 127.0.0.1
ll /var/lib/vdr/data/.pulse/
-rw-r--r--. 1 vdr video 43  5. Jul 19:38 client.conf
1 Like

Did you follow instructions from somewhere? If so please link the reference. If not then changes certainly seem arbitrary.

Was vdr installed from a fedora supporting repo or from some other source? Does vdr support use with pipeware/wireplumber or is it still tied to pulse audio?

Looking at those audio changes that have occurred with fedora in recent releases might point you in the proper direction. Fedora does not use pulse audio at the present (and has not since either F32 or F33). Pipewire has replaced it and if vdr is dependent upon pulse then it will require some adjustments, possibly even some reprogramming of vdr to support the new audio system in use today.

While this is all conjecture, I did the following to see if vdr was available for fedora 36 and with it available from fedora there really should be no need for changes to the config.

$ sudo dnf install vdr
Last metadata expiration check: 3:50:18 ago on Tue 05 Jul 2022 08:59:37 AM CDT.
Dependencies resolved.
==================================================================================================================================
 Package                            Architecture              Version                             Repository                 Size
==================================================================================================================================
Installing:
 vdr                                x86_64                    2.6.1-1.fc36                        fedora                    1.2 M
Installing dependencies:
 vdrsymbol-fonts                    noarch                    20100612-22.fc36                    fedora                    496 k

Transaction Summary
==================================================================================================================================
Install  2 Packages

Total download size: 1.7 M
Installed size: 5.2 M
Is this ok [y/N]: 
Operation aborted.

The Video Disc Recorder (vdr) uses a plugin that accesses the alsa device.
I followed the following description Pulseaudio for multiple users, without system-mode daemon
or Multi-user audio sharing with PipeWire / Multimedia and Games / Arch Linux Forums
Unfortunately you can’t use the description 1:1, because the configuration has changed a lot.

Of course I installed vdr from the official repo, (I am the maintainer of the vdr Fedora package).

The vdr-plugin uses alsa, which can be seen in journalctl -u vdr.service.

vdr[1079]: audio: 'alsa' output module used
Jul 05 20:10:09 fc36 vdr[1079]: audio/alsa: supports pause: yes
Jul 05 20:10:09 fc36 vdr[1079]: audio/alsa: can't open mixer 'default'
Jul 05 20:10:09 fc36 vdr[1079]: audio:  44100Hz supports 0 0 0 0 0 0 0 0 channels
Jul 05 20:10:09 fc36 vdr[1079]: audio:  48000Hz supports 0 0 0 0 0 0 0 0 channels
Jul 05 20:10:09 fc36 vdr[1079]: audio: 192000Hz supports 0 0 0 0 0 0 0 0 channels

I also get a sound output, but not always, as Pulseaudio has the alsa device in access,
and so I wanted to set up a Pulseaudio server to determine if it works better with that.

Why does i get the pulseserver running on my virtual fedora test system ?

[martin@fc36 ~]$ pactl info
Server String: tcp:127.0.0.1:4713
Library Protocol Version: 35
Server Protocol Version: 35
Is Local: no
Client Index: 68
Tile Size: 65472
User Name: martin
Host Name: fc36
Server Name: PulseAudio (on PipeWire 0.3.53)
Server Version: 15.0.0
Default Sample Specification: float32le 2ch 44100Hz
Default Channel Map: front-left,front-right
Default Sink: alsa_output.pci-0000_02_01.0.analog-stereo
Default Source: alsa_input.pci-0000_02_01.0.analog-stereo
Cookie: 712a:c78f

Now I have to test further.

I rejoiced too soon, it doesn’t work again. :confused:

While I do not use pulseaudio, but instead am quite happy with the default pipewire, I have seen several posts about how to replace pipewire with pulseaudio.
IIRC it can be done with something similar to dnf swap --allowerasing pipewire pulseaudio . Then a reboot will start the system with pulseaudio server running.

It also seems that pulse can be emulated by pipewire if the pipewire-pulseaudio package is installed

now I have the pulse server up and running, I still had to activate the pipewire-pulse service.

[martin@fc36 ~]$ systemctl --user enable pipewire-pulse.service

[martin@fc36 ~]$ systemctl --user list-unit-files|grep wire
pipewire-pulse.service enabled disabled
pipewire-session-manager.service alias -
pipewire.service disabled disabled
wireplumber.service enabled enabled
wireplumber@.service disabled disabled
pipewire-pulse.socket enabled enabled
pipewire.socket enabled enabled

[martin@fc36 ~]$ pactl info

Server String: tcp:127.0.0.1:4713
Library Protocol Version: 35
Server Protocol Version: 35
Is Local: no
Client Index: 78
Tile Size: 65472
User Name: martin
Host Name: fc36
Server Name: PulseAudio (on PipeWire 0.3.53)
Server Version: 15.0.0
Default Sample Specification: float32le 2ch 48000Hz
Default Channel Map: front-left,front-right
Default Sink: alsa_output.pci-0000_02_01.0.analog-stereo
Default Source: alsa_output.pci-0000_02_01.0.analog-stereo.monitor
Cookie: d8ba:190e