Adamcake / Bolt

An alternative launcher for your favourite MMO
GNU Affero General Public License v3.0
122 stars 18 forks source link

No sound using Runelite (Pulseaudio) #12

Closed ShadowBladezx86 closed 6 months ago

ShadowBladezx86 commented 6 months ago

When launching Runelite I get no sound output, and when running Bolt from the terminal I see the following messages:

2023-12-27 00:26:22 CST [main] INFO  n.r.client.config.ConfigManager - Profile '$rsprofile' is up to date
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
Failed to create secure directory (/run/user/1000/bolt-runelite-ucFzrN/pulse): Too many levels of symbolic links
2023-12-27 00:26:23 CST [main] INFO  n.r.c.plugins.kourendlibrary.Library - Library is now reset

Checking out the directory structure, it looks like this:

[username@BlackFox bolt-runelite-ucFzrN]$ ls -ln /run/user/1000/bolt-runelite-ucFzrN
total 0
lrwxrwxrwx 1 1000 1000 21 Dec 27 00:26 at-spi -> /run/user/1000/at-spi
lrwxrwxrwx 1 1000 1000 35 Dec 27 00:26 bolt-runelite-7GtAIl -> /run/user/1000/bolt-runelite-7GtAIl
lrwxrwxrwx 1 1000 1000 35 Dec 27 00:26 bolt-runelite-gqpzaR -> /run/user/1000/bolt-runelite-gqpzaR
lrwxrwxrwx 1 1000 1000 35 Dec 27 00:26 bolt-runelite-T6a7C7 -> /run/user/1000/bolt-runelite-T6a7C7
lrwxrwxrwx 1 1000 1000 35 Dec 27 00:26 bolt-runelite-ucFzrN -> /run/user/1000/bolt-runelite-ucFzrN
lrwxrwxrwx 1 1000 1000 18 Dec 27 00:26 bus -> /run/user/1000/bus
lrwxrwxrwx 1 1000 1000 25 Dec 27 00:26 ccache-tmp -> /run/user/1000/ccache-tmp
lrwxrwxrwx 1 1000 1000 21 Dec 27 00:26 dbus-1 -> /run/user/1000/dbus-1
lrwxrwxrwx 1 1000 1000 20 Dec 27 00:26 dconf -> /run/user/1000/dconf
lrwxrwxrwx 1 1000 1000 28 Dec 27 00:26 discord-ipc-0 -> /run/user/1000/discord-ipc-0
lrwxrwxrwx 1 1000 1000 28 Dec 27 00:26 discord-ipc-1 -> /run/user/1000/discord-ipc-1
lrwxrwxrwx 1 1000 1000 18 Dec 27 00:26 doc -> /run/user/1000/doc
lrwxrwxrwx 1 1000 1000 18 Dec 27 00:26 gcr -> /run/user/1000/gcr
lrwxrwxrwx 1 1000 1000 20 Dec 27 00:26 gnupg -> /run/user/1000/gnupg
lrwxrwxrwx 1 1000 1000 19 Dec 27 00:26 gvfs -> /run/user/1000/gvfs
lrwxrwxrwx 1 1000 1000 24 Dec 27 00:26 gvfs-burn -> /run/user/1000/gvfs-burn
lrwxrwxrwx 1 1000 1000 20 Dec 27 00:26 gvfsd -> /run/user/1000/gvfsd
lrwxrwxrwx 1 1000 1000 27 Dec 27 00:26 ICEauthority -> /run/user/1000/ICEauthority
lrwxrwxrwx 1 1000 1000 22 Dec 27 00:26 KeePass -> /run/user/1000/KeePass
lrwxrwxrwx 1 1000 1000 22 Dec 27 00:26 keyring -> /run/user/1000/keyring
lrwxrwxrwx 1 1000 1000 22 Dec 27 00:26 p11-kit -> /run/user/1000/p11-kit
lrwxrwxrwx 1 1000 1000 25 Dec 27 00:26 pipewire-0 -> /run/user/1000/pipewire-0
lrwxrwxrwx 1 1000 1000 30 Dec 27 00:26 pipewire-0.lock -> /run/user/1000/pipewire-0.lock
lrwxrwxrwx 1 1000 1000 33 Dec 27 00:26 pipewire-0-manager -> /run/user/1000/pipewire-0-manager
lrwxrwxrwx 1 1000 1000 38 Dec 27 00:26 pipewire-0-manager.lock -> /run/user/1000/pipewire-0-manager.lock
lrwxrwxrwx 1 1000 1000 20 Dec 27 00:26 pulse -> /run/user/1000/pulse
lrwxrwxrwx 1 1000 1000 22 Dec 27 00:26 systemd -> /run/user/1000/systemd
[username@BlackFox bolt-runelite-ucFzrN]$ ls -ln /run/user/1000
total 4
drwx------ 2 1000 1000  60 Dec 22 22:40 at-spi
drwx------ 2 1000 1000 520 Dec 27 00:20 bolt-runelite-7GtAIl
drwx------ 2 1000 1000 540 Dec 27 00:23 bolt-runelite-gqpzaR
drwx------ 2 1000 1000 560 Dec 27 00:24 bolt-runelite-T6a7C7
drwx------ 2 1000 1000 580 Dec 27 00:26 bolt-runelite-ucFzrN
srw-rw-rw- 1 1000 1000   0 Dec 22 22:40 bus
drwxr-xr-x 2 1000 1000  80 Dec 27 00:15 ccache-tmp
drwx------ 3 1000 1000  60 Dec 22 22:40 dbus-1
drwx------ 2 1000 1000  40 Dec 27 00:24 dconf
srwxr-xr-x 1 1000 1000   0 Dec 25 21:42 discord-ipc-0
srwxr-xr-x 1 1000 1000   0 Dec 23 16:45 discord-ipc-1
dr-x------ 2 1000 1000   0 Dec 31  1969 doc
drwx------ 2 1000 1000  60 Dec 22 22:40 gcr
drwx------ 2 1000 1000 160 Dec 22 22:40 gnupg
dr-x------ 2 1000 1000   0 Dec 22 22:40 gvfs
drwx------ 2 1000 1000  40 Dec 22 22:40 gvfs-burn
drwx------ 2 1000 1000  40 Dec 25 01:19 gvfsd
-rw------- 1 1000 1000 326 Dec 22 22:40 ICEauthority
drwxr-xr-x 2 1000 1000  80 Dec 22 22:40 KeePass
drwx------ 2 1000 1000  80 Dec 22 22:40 keyring
drwxr-xr-x 2 1000 1000  60 Dec 22 22:40 p11-kit
srw-rw-rw- 1 1000 1000   0 Dec 22 22:40 pipewire-0
-rw-r----- 1 1000 1000   0 Dec 22 22:40 pipewire-0.lock
srw-rw-rw- 1 1000 1000   0 Dec 22 22:40 pipewire-0-manager
-rw-r----- 1 1000 1000   0 Dec 22 22:40 pipewire-0-manager.lock
drwx------ 2 1000 1000 100 Dec 25 12:03 pulse
drwxr-xr-x 6 1000 1000 160 Dec 22 22:40 systemd

On a sidenote, it seems it doesn't clean up old symbolic links.

Adamcake commented 6 months ago

It looks like it created the pulse directory just fine, so not sure why it's claiming it can't. Is switching to pipewire an option? In my experience it works better in general. Either way I'll try to recreate this later.

it seems it doesn't clean up old symbolic links

I don't have an option for doing that really. The launcher can't clear out the directory because the launcher might be closed before the game, and the directory needs to exist at least as long as the game instance. I would need the game to cleanup on exit, but that's not a config option in either runelite or the JVM. The directories will be cleared on reboot though (as per FHS spec).

But now I think about it, I could have a shell do this for me.

ShadowBladezx86 commented 6 months ago

Thanks for responding. I have now switched over to pipewire. I just needed more than 1 thing to push me over.

Adamcake commented 6 months ago

In case any future travelers find this issue: it looks like it can be fixed by setting the environment variable PULSE_RUNTIME_PATH to /run/user/1000/pulse (or whatever the correct path would be on your system, relative to XDG_RUNTIME_DIR). This would bypass the issue, which otherwise appears to be a bug in PulseAudio.

Reference: https://github.com/pulseaudio/pulseaudio/blob/06ccfbb996e5b8b31f04f97795e8c9f083bea332/src/pulsecore/core-util.c#L1759-L1806