NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
18.38k stars 14.33k forks source link

OpenRGB crashes #267915

Open suhr opened 1 year ago

suhr commented 1 year ago

Describe the bug

Attempting to connect to local OpenRGB server.
Connection attempt failed
Local OpenRGB server unavailable.
Running standalone.
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
*** buffer overflow detected ***: terminated

Steps To Reproduce

Steps to reproduce the behavior:

  1. nix shell 'self#openrgb'
  2. sudo openrgb

Expected behavior

OpenRGB should not crash.

Notify maintainers

@jonringer

Metadata

Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.

[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
 - system: `"x86_64-linux"`
 - host os: `Linux 6.6.0, NixOS, 23.11 (Tapir), 23.11.20231112.e44462d`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.1`
 - channels(root): `"nixos"`
 - channels(suhr): `""`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
hcwf commented 10 months ago

I'm facing the same problem. I first got it to run without any problems, but after upgrading my setup with some new fans OpenRGB has been failing on my NixOS machine. Now I get the same error as shown by @suhr.

jonringer commented 10 months ago

Does services.hardware.openrgb.enable work?

Although this looks like a potential packaging issue, or upstream issue

hcwf commented 10 months ago

I got the OpenRGB server to run with this config:

{ config, pkgs, ... }:

{
  boot = {
    kernelParams = [ "acpi_enforce_resources=lax" ];
    kernelModules = [ "i2c-dev" "i2c-piix4" ];
  };

  hardware = {
    i2c = {
      enable = true;
    };
  };

  environment.systemPackages = with pkgs; [
    i2c-tools
    liquidctl
  ];

  services = {
    hardware.openrgb = {
      enable = true;
      motherboard = "amd";
    };
  };
}

It now runs consistently when logging in, but still has some problems with crashes where I need to restart the computer to get the server running again. Those mostly happen when changing configs in the OpenRGB GUI. It does work most of the time though, so I'm happy for now.

Continous commented 2 weeks ago

I was able to resolve crashing by not detecting my GPU. Is it possible that this is an upstream issue? Or maybe a NixOS-unique permissions issue?