XAuthority Cookies and Mode1 Errors

I have used CoolerControl with my GTX 1070 card on other distributions like Fedora and Debian without any issues, but it just doesn’t work on NixOS. I’m using proprietary production Nvidia drivers. This is what my driver module currently looks like:

{
  config,
  pkgs,
  ...
}: {
  services.xserver.videoDrivers = ["nvidia"];

  hardware = {
    nvidia = {
      powerManagement = {
        enable = false;
        finegrained = false;
      };

      modesetting.enable = true;
      open = false;
      nvidiaSettings = true;
      package = config.boot.kernelPackages.nvidiaPackages.production;
    };

    opengl = {
      enable = true;
      driSupport = true;
      driSupport32Bit = true;
    };
  };
}

This is my CoolerControl module:

{
  programs.coolercontrol = {
    enable = true;
    nvidiaSupport = true;
  };
}

I’m getting the following errors:

Input: coolercontrol

Output:

\*\* (coolercontrol:12991): WARNING \*\*: 23:05:53.283: webkit\_settings\_set\_enable\_offline\_web\_application\_cache is deprecated and does nothing. Could not determine the accessibility bus address

Input: sudo systemctl status coolercontrold

Output (actual host name replaced with <MY HOST NAME HERE>):

● coolercontrold.service - CoolerControl Daemon Loaded: loaded (/etc/systemd/system/coolercontrold.service; enabled; preset: enabled) Drop-In: /nix/store/ln3zvlnkynskgqm3mb82mbzr8zfy15zr-system-units/coolercontrold.service.d └─overrides.conf Active: active (running) since Thu 2024-05-23 21:36:10 +06; 1h 27min ago Main PID: 1072 (coolercontrold) IP: 105.2K in, 14.3M out IO: 14.6M read, 32.0K written Tasks: 15 (limit: 19118) Memory: 63.2M (peak: 78.5M) CPU: 1min 31.476s CGroup: /system.slice/coolercontrold.service └─1072 /nix/store/racw52cqg7llndjqgndj3mr14nd7njav-coolercontrold-1.2.2/bin/coolercontrold

    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Nvidia device detected but no xauthority cookie found which is needed for proper communication with nvidia-settings. Nvidia Fan Control disabled.
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Initialized GPU Devices: ["NVIDIA GeForce GTX 1070"]
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Initialized Hwmon Devices: ["acpitz"]
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Initialized Custom Sensors: []
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Applying all saved device settings
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Mode contains no setting for device UID: fa37bdabbb2f784366ba2c864463038b3018320135790445216f64ee2fae9122. Please update your mode: Mode 1.
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: API bound to IPv4 and IPv6 addresses: , [::1]:11987
    May 23 21:36:23 <MY HOST NAME HERE> coolercontrold[1072]: Daemon successfully initialized
    May 23 22:53:41 <MY HOST NAME HERE> coolercontrold[1072]: Mode contains no setting for device UID: fa37bdabbb2f784366ba2c864463038b3018320135790445216f64ee2fae9122. Please update your mode: Mode 1.
    May 23 22:54:37 <MY HOST NAME HERE> coolercontrold[1072]: Mode contains no setting for device UID: fa37bdabbb2f784366ba2c864463038b3018320135790445216f64ee2fae9122. Please update your mode: Mode 1.127.0.0.1:11987

I should also mention that I have tried using other, inferior, utilities for controlling my GPU fans speeds, but I’m also getting errors. Any idea how to fix this?

Any help will be greatly appreciated! Thank you in advance!

Are you on X or wayland? Both plasma and gnome use wayland by default these days, but some other distros have chosen not to upgrade them for now, so that may be the difference.

FWIW, I think nvidia-settings can actually control fans from wayland nowadays.

Thanks for the reply! I’m using Wayland.

nvidia-settings options are very limited; you can only set the fan speed to a fixed value. CoolerControl allows curves.

To my knowledge, there should be no xauthority cookie on wayland, which seems to not mesh well with this tool. I think you’ll have to ask upstream how to get this to work on wayland.

I have tried to get it running on XFCE, but encountered the same errors.