tailscale: nix-store --serve protocol mismatch from root@nas

What is the issue?

I’d like to use tailscale’s MagicDNS feature to build my other NixOS machines remotely. However, I’m getting the following error message for example if I try to deploy the NixOS config for my nas:

/nix/store/gff1a9d97z9y776x6c8illqgnls1vp9m-set-environment: line 16: warning: setlocale: LC_NUMERIC: cannot change locale (de_DE.UTF-8): No such file or directory
/nix/store/gff1a9d97z9y776x6c8illqgnls1vp9m-set-environment: line 19: warning: setlocale: LC_TIME: cannot change locale (de_DE.UTF-8): No such file or directory
error: 'nix-store --serve' protocol mismatch from 'root@nas'

Steps to reproduce

  1. Install NixOS on two systems
  2. Enable MagicDNS + tailscale-ssh on both systems
  3. Add ssh keys to remote system for user root
  4. Execute nixos-rebuild switch --flake .#<name of the remote system> --target root@<hostname of the remote system>

Are there any recent changes that introduced the issue?

No

OS

Linux, Other

OS version

nixos-24.05

Tailscale version

1.76.6, go version: go1.23.1

Other software

Don’t know what to enter here.

Bug report

BUG-88f44b90e276f62476982e9485003b53a27f29cde3eb624af9291dc0550ef558-20241114104317Z-b8803dd552bc9570

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Reactions: 5
  • Comments: 16 (7 by maintainers)

Most upvoted comments

Thanks @TornaxO7 . I’m reaching out to some NixOS users internally to see if someone else can reproduce the problem.

@oxtoacart I copy+pasted your given setup to the Access Controls json file but I’m still getting the same error messag.

hm… ok no, looks like as if nothing changed. I set it to “no” and executed nixos-rebuild switch on my pc + nas.

@TornaxO7 Thanks for reporting this. I’m curious, do the --show-trace and/or --verbose flags show any of the SSH protocol details?

When executing nixos-rebuild switch --flake .#nas --target-host root@nas --verbose:

$ nix --extra-experimental-features nix-command flakes build --out-link /tmp/nixos-rebuild.JEDe6m/nixos-rebuild .#nixosConfigurations."nas".config.system.build.nixos-rebuild --verbose
fetching git input 'git+file:///home/tornax/dotfiles'
$ exec /nix/store/dk8i9cjbmdmygqc452v44jwah0f3sgc5-nixos-rebuild/bin/nixos-rebuild switch --flake .#nas --target-host root@nas --verbose
building the system configuration...
Building in flake mode.
$ nix --extra-experimental-features nix-command flakes build .#nixosConfigurations."nas".config.system.build.toplevel --verbose --out-link /tmp/nixos-rebuild.Ywaz5w/result
fetching git input 'git+file:///home/tornax/dotfiles'
Running nix-copy-closure with these NIX_SSHOPTS:  -o ControlMaster=auto -o ControlPath=/tmp/nixos-rebuild.Ywaz5w/ssh-%n -o ControlPersist=60
$ nix-copy-closure --to root@nas /nix/store/f5fsxl0sb86gjkvd6rfl65s0vzfkad1y-nixos-system-nas-24.05.20241116.e8c38b7
/nix/store/7zmn0k8xs6lkqz7fhkdgi2hxsbzyj1g6-set-environment: line 16: warning: setlocale: LC_NUMERIC: cannot change locale (de_DE.UTF-8): No such file or directory
/nix/store/7zmn0k8xs6lkqz7fhkdgi2hxsbzyj1g6-set-environment: line 19: warning: setlocale: LC_TIME: cannot change locale (de_DE.UTF-8): No such file or directory
error: 'nix-store --serve' protocol mismatch from 'root@nas'

When using nixos-rebuild switch --flake .#nas --target-host root@nas --show-trace:

building the system configuration...
/nix/store/7zmn0k8xs6lkqz7fhkdgi2hxsbzyj1g6-set-environment: line 16: warning: setlocale: LC_NUMERIC: cannot change locale (de_DE.UTF-8): No such file or directory
/nix/store/7zmn0k8xs6lkqz7fhkdgi2hxsbzyj1g6-set-environment: line 19: warning: setlocale: LC_TIME: cannot change locale (de_DE.UTF-8): No such file or directory
error: 'nix-store --serve' protocol mismatch from 'root@nas'