Skip to content
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

nixos-install unstable 16.03pre69762 fails #10230

Closed
ghost opened this issue Oct 4, 2015 · 8 comments
Closed

nixos-install unstable 16.03pre69762 fails #10230

ghost opened this issue Oct 4, 2015 · 8 comments
Labels
6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS

Comments

@ghost
Copy link

ghost commented Oct 4, 2015

installing from unstable nixos machine to /mnt; nixos-install fails:

/nix/store/ycl4b69q5k43z0cnyyl8dw4w52jid3na-stage-1-init.sh.drv
/nix/store/rhga7k8yismf8fr4acp8cra5zmgfvc4x-initrd.drv
/nix/store/ylz62ka1qap5jnvf58f4i5ynq7hbcd6g-users-groups.json.drv
/nix/store/rrg5li911g26s76k3rkcksxzypxh93k6-nixos-system-nixos-16.03pre69762.e916273.drv
these paths will be fetched (0.00 MiB download, 8.32 MiB unpacked):
/nix/store/8ignm13qyb4npb00y01yj6szj9zhhj62-libXt-1.1.5
/nix/store/azadkmfzykwb8h1y007831zwd8vbz2li-libXmu-1.1.2
/nix/store/gsc42mc0vqfpl8d078zm07jy5xva7r4w-libX11-1.6.3
/nix/store/r3xv21sfbky2pi0x8gypidal63m057f7-libxcb-1.11.1
/nix/store/r457i29jhs433sgj7dnv02a2jrf2j0qz-dbus-tools-1.8.20
/nix/store/w7rkbg3vsvbpcw6zfy5dahlrf41wp3js-xauth-1.0.9
/nix/store/wncmry3c49vgkg7y4c72s1khwzkzhggq-libXext-1.3.3
building path(s) ‘/nix/store/0r3h90h24qdb7jaqyyxd63k5fh3d1clk-users-groups.json’
while setting up the build environment: executing ‘/nix/store/xag5ayq906w9zhlxs8wayv4kvpiyqphq-bash-4.3-p42/bin/bash’: Permission denied
builder for ‘/nix/store/ylz62ka1qap5jnvf58f4i5ynq7hbcd6g-users-groups.json.drv’ failed with exit code 1
cannot build derivation ‘/nix/store/rrg5li911g26s76k3rkcksxzypxh93k6-nixos-system-nixos-16.03pre69762.e916273.drv’: 1 dependencies couldn't be built
error: build of ‘/nix/store/rrg5li911g26s76k3rkcksxzypxh93k6-nixos-system-nixos-16.03pre69762.e916273.drv’ failed

@domenkozar domenkozar added the 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS label Oct 7, 2015
@ghost
Copy link
Author

ghost commented Oct 25, 2015

I can run /nix/store/xag5ayq906w9zhlxs8wayv4kvpiyqphq-bash-4.3-p42/bin/bash without problems so the rights are fine. DerivationGoal::runChild method has 378 lines so it is not clear what should I be focusing on.

@rnhmjoj
Copy link
Contributor

rnhmjoj commented Nov 18, 2015

It fails for me too on generating users-groups.json but for another reason. It says that the directory /run/users does not exist but in fact it's right there.

@elitak
Copy link
Contributor

elitak commented Mar 14, 2016

(POTENTIAL WORKAROUND)

I was running into this problem on every nix+nixpkgs version combo I tried. Sometimes it would be on a different "audit" derivation instead. The cause turned out to be that I was running nixos-install targeting a bind-mount. As soon as I switched to a loopback-mounted ext4.img, everything ran fine. I guess nixos-install has some weird mount-related internals that get broken by bind-type mounts. Another error I ran into under similar circumstances complained about something like "unshare" not working.

I really think nixos-install should support bind-mounts and even no mounts at all (just point it to an empty directory) or at least have good documentation as to why they can't be supported and give better error messages.

@elitak
Copy link
Contributor

elitak commented Apr 9, 2016

I had a lot of trouble trying to get any more details out of nixos-install trace log and gave up.

To reproduce:
Deploy a fresh ubuntu/debian vm and run basically theses steps, but instead of loopback mounting an ext4 image, just bindmount (or no mount) the target directory:
https://gist.github.com/elitak/996e3b3c54c07409c8f2

@domenkozar
Copy link
Member

Are these errors still present?

@rnhmjoj
Copy link
Contributor

rnhmjoj commented Sep 13, 2016

It has never happened again for me but possibly mine was a different issue. I don't know about the others.

@elitak
Copy link
Contributor

elitak commented Sep 16, 2016

I tried briefly to reproduce, but failed. It's no longer blocking me anyway.

@domenkozar
Copy link
Member

Please reopen if issue persists :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS
Projects
None yet
Development

No branches or pull requests

3 participants