Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pipewire-pulse gets killed whenever something tries to use it #334140

Open
diniamo opened this issue Aug 12, 2024 · 20 comments
Open

pipewire-pulse gets killed whenever something tries to use it #334140

diniamo opened this issue Aug 12, 2024 · 20 comments
Labels
0.kind: bug Something is broken

Comments

@diniamo
Copy link
Contributor

diniamo commented Aug 12, 2024

Describe the bug

The title says everything, by "whenever something tries to use it", I mean when something tries to play audio, or query data (eg.: control programs like pavucontrol or pulsemixer).

Steps To Reproduce

I have no idea, I haven't opened an issue, because with my luck, this could have been one of a kind, but I found someone else who has this.

Expected behavior

Pipewire-pulse and applications that use the pulse backend work fine.

Additional context

Dmesg doesn't contain any messages about the OOM killer being the culprit.

Is there any way to figure out what's killing it?

Notify maintainers

@K900 (I know you've tried to help, but tagging nonetheless)

Metadata

[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
 - system: `"x86_64-linux"`
 - host os: `Linux 6.10.3, NixOS, 24.11 (Vicuna), 24.11.20240812.9fa5c97`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Lix, like Nix) 2.90.0-rc1`
 - nixpkgs: `/nix/store/vsrna35znxh8phnf7xywxqw3il9201kw-source`

Add a 👍 reaction to issues you find important.

@diniamo diniamo added the 0.kind: bug Something is broken label Aug 12, 2024
@K900
Copy link
Contributor

K900 commented Aug 12, 2024

Is it actually being killed, or is it crashing? Do you have a core dump?

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

pipewire-pulse.service: Main process exited, code=killed, status=9/KILL

@K900
Copy link
Contributor

K900 commented Aug 12, 2024

Try running it along with killsnoop from bcc, that should tell you what is killing every process.

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

Doesn't give me anything for pipewire-pulse, works for other programs though.

@K900
Copy link
Contributor

K900 commented Aug 12, 2024

That is very strange. Actually, are you using the hardened profile or anything like that?

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

Hardened profile where?

@K900
Copy link
Contributor

K900 commented Aug 12, 2024

In your NixOS config. Can you post your entire configuration, actually?

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

@K900
Copy link
Contributor

K900 commented Aug 12, 2024

It's very hard to figure out what is going on there. What does echo $LD_PRELOAD output?

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

It's empty.

@K900
Copy link
Contributor

K900 commented Aug 12, 2024

At this point the only idea I can think of is to run it under a debugger and observe.

@diniamo
Copy link
Contributor Author

diniamo commented Aug 12, 2024

I'm not sure why a debugger would give me anything when it's just killed. Either way running it under gdb does, in fact, not give me anything. Otherwise, what did you mean?

@AhuracMusic
Copy link

Bumping this to share a fix. For some reason, enabling rtkit worked for me. You already had it enabled at the time so we still don't know why this happens.

{
  security.rtkit.enable = true;
}

@diniamo
Copy link
Contributor Author

diniamo commented Nov 6, 2024

I didn't though?

@AhuracMusic
Copy link

I think I misread your conf, in /modules/workstation/gaming.nix the line about rtkit isn't unconditionally applied ?
If you found another workaround, I'm curious. Otherwise, you have this trick in the meantime.

@Frontear
Copy link
Member

Frontear commented Nov 7, 2024

I wonder if this may have any relation to #348155

@AhuracMusic
Copy link

In my case the socket succeeds to launch pipewire-pulse.service, it's just that it gets killed whenever a program uses it.

@diniamo
Copy link
Contributor Author

diniamo commented Nov 7, 2024

I think I misread your conf, in /modules/workstation/gaming.nix the line about rtkit isn't unconditionally applied ? If you found another workaround, I'm curious. Otherwise, you have this trick in the meantime.

@AhuracMusic That module isn't enabled on my laptop.

@SpiderUnderUrBed
Copy link

SpiderUnderUrBed commented Nov 7, 2024

I am having a similar bug on hyprland enabled via home-manager, and I expect the same issue to be present if hyprland was enabled in nixos:
nix-community/home-manager#6044
I tried enabling rtkit (by that I mean it was already enabled) and the issue was not fixed, also, when I try to play a youtube video, I do not notice pipewire-pulse crashing, its systemd logs show that its up and running. However the youtube video cannot play as it cannot connect to pipewire-pulse. When I tried to run pavucontrol, I noticed that it was stuck trying to look for pulseaudio. So my assumtion is that hyprland cannot access pipewire or pulseaudio, I was talking about this with a few people, one of them mentioned dbus access, however I dont know any more debugging steps I can take at this moment to confirm or deny the cause, several other people are experiencing this issue on hyprland and XFCE.

@diniamo
Copy link
Contributor Author

diniamo commented Nov 7, 2024

Once again, this has nothing to do with Hyprland.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.kind: bug Something is broken
Projects
None yet
Development

No branches or pull requests

5 participants