-
-
Notifications
You must be signed in to change notification settings - Fork 363
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
Hangs at copying closure...
#1557
Comments
I had the same problem and after some investigation I determined that it was due to using let
# As of 2023-04-19, nix 2.15 breaks nixops: it becomes stalled at "copying closure" step
# Use latest version known to be working, 2.14.1
currentMasterPkgs = import (builtins.fetchTarball {
url = "https://github.com/NixOS/nixpkgs/archive/8ad5e8132c5dcf977e308e7bf5517cc6cc0bf7d8.tar.gz";
}) {};
nix214 = currentMasterPkgs.nixVersions.nix_2_14;
in mkShell {
buildInputs = [
nix214
pkgs.nixops
];
} |
@lelit you are a life-saver. $ nix shell github:nixos/nixpkgs/8ad5e8132c5dcf977e308e7bf5517cc6cc0bf7d8#nix -c nixops deploy working like a charm. Is this a documented issue somewhere else? If not I'll start a bisect -- I'm not even sure if the issue would belong here, at nixpkgs/nix, or elsewhere. |
I looked around but did not find anything. I identified latest nix as the culprit by sheer luck, knowing that the previous deploy of a week before worked as usual, and the only difference on my work machine has been a monthly update of its NixOS. |
Thanks for the workaround! A slightly less reproducable but easier to remember nix-shell command: |
So glad to have finally found this - is there an issue opened against NixOs/nix for this? |
I tried to make a script to bisect nixpkgs but couldn't find the culprit commit. Maybe I'm bisecting the wrong codebase. |
There is a bug in Nix 2.15 where NixOps does not work anymore. See: NixOS/nixops#1557
Just investigating this a little... nixops is running
|
Is the first bad commit on nix. |
That's what I was finding: if you run the command without -oControlPath, it works great. With, it hangs, and because |
That checks out with NixOS/nix#8329. I did find that downgrading my NixOps shell.nix to Nix 2.13 fixed the issue. |
NixOS/nix#8329 was fixed, but only for cases where the master could be found without NIX_SSHOPTS. The remaining issue is NixOS/nix#8480, and my proposed fix is in NixOS/nix#8506. |
This seems fixed. Tested on nixos-unstable. Can someone second this and we can close? |
Yes, with:
... |
I have a nixops configuration (my first one) that has been working for a couple months. Earlier this week I went to redeploy (without config changes, trying to debug an intermittent docker issue on the target machine) and it hung at
copying closure...
. Since then it hangs here every time. I've tried running with--debug
and no relevant additional information is printed.I've tried rebooting the target machine,
nixos-rebuild --rollback
to a prior working generation on the target machine, updatingnixopsUnstable
on the host machine.rsync
ing the config over and doingnixos-rebuild switch
locally works without errors (I have it set up so it uses the same config through nixops).Are there other debugging steps I can take?
The text was updated successfully, but these errors were encountered: