Steam 'Steam library folder is not writable'

Hi all,
Im new to the whole NixOS, installed for the first time yesterday and trying to piece everything together.

My issue is ive installed Steam but when I try to direct it to my external drives steam library it doesnt seem to have the permissions to write with the message ‘Steam library is not writable’

Is the application acting as another user and cannot access the files, the only quirk I have is my external drive is a Windows software spanned drive on btrfs which ive pulled into nix with ldmtool.

Anyone able to assist? Thanks

{ config, pkgs, ... }:

{
  # -------------------------------------------------------------------
  # Systemd Service for Local Data Manager (LDM)
  # -------------------------------------------------------------------
  systemd.services.local-data-manager = {
    enable = true;  # Enable the Local Data Manager service
    description = "Local Data Manager";  # Service description
    after = [ "local-fs-pre.target" ];  # Ensure LDM starts after filesystem is mounted
    serviceConfig = {
      Type = "forking";  # Service forks into the background
      User = "root";  # Run as root user
      ExecStart = "/run/current-system/sw/bin/ldmtool create all";  # Command to start LDM
      Restart = "on-failure";  # Restart service on failure
      Environment = "PATH=/run/current-system/sw/bin:/usr/bin:/bin";  # Set PATH for environment
    };
    wantedBy = [ "multi-user.target" ];  # Enable service at multi-user target (default system startup)
  };
  # -------------------------------------------------------------------
  # Define User "ljam" with Custom Groups and Packages
  # -------------------------------------------------------------------
  users.users.ljam = {
    isNormalUser = true;  # Regular user (non-root)
    description = "ljam";  # User description
    extraGroups = [ "networkmanager" "wheel" "docker" "libvirtd" ];  # Groups for network management and sudo access
    packages = with pkgs; [
      # Add user-specific packages here
    ];
  };
  # -------------------------------------------------------------------
  # Steam Settings (Gaming Setup)
  # -------------------------------------------------------------------
  programs.steam = {
    enable = true;  # Enable Steam
    remotePlay.openFirewall = true;  # Open firewall ports for Steam Remote Play
    dedicatedServer.openFirewall = true;  # Open firewall ports for Source Dedicated Server
  };


drwxrwxr-x 1 ljam users    140 Mar 18 11:51 .
drwxrwxr-x 1 ljam users     54 Mar 10 17:48 ..
-rwxr-xr-x 1 ljam users     68 Mar 17 15:43 libraryfolder.vdf
-rwxrwxr-x 1 ljam users      9 Oct 14 11:41 steam_appid.txt
drwxrwxr-x 1 ljam users   3346 Mar 17 21:49 steamapps
-rwxrwxr-x 1 ljam users 504680 May 30  2023 steam.dll
-rwxrwxr-x 1 ljam users      0 Feb 11 23:06 .temp_write_2138be19
[ljam@desktop-nixos:/mnt/Nostromo/Video Games/Steam]$ mount | grep Nostromo
/dev/mapper/ldm_vol_DESKTOP-U97DQQO-Dg0_Volume1 on /mnt/Nostromo type btrfs (rw,nosuid,nodev,relatime,ssd,discard=async,space_cache=v2,subvolid=5,subvol=/,x-gvfs-show)

Where have you mounted your drive?
Had the same problem and even after setting permissions it stopped working after some time (had it mounted in /mnt too).
Pleas try mounting your drive in your home-directory. There steam should have no problems.

Thank you!, that did it, I made a /mnt folder in my user directory and its working fine now :+1:

1 Like