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-enter: Ensures presence of full /sys tree. (for efivarfs) #39342

Merged
merged 1 commit into from Apr 23, 2018

Conversation

samueldr
Copy link
Member

@samueldr samueldr commented Apr 22, 2018

This partially reverts a change from e88f289 which removed the mount --rbind /sys.

While true that the activation scripts will mount sysfs at /sys, none of the mountpoints lower in the /sys tree are handled by the activation script, which includes efivarfs.

Motivation for this change

This fixes #38477 since it ensures the presence of efivarfs in the /sys tree, which is why the systemd-boot installation failed.

Things done
  • ☑️ Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • ☑️ NixOS
    • ⬜ macOS
    • ⬜ other Linux distributions
  • ⬜ Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • ⬜ Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • ☑️ Tested execution of all binary files (usually in ./result/bin/)
  • ☑️ Fits CONTRIBUTING.md.

Tested by:

  • Executing in qemu with efi exec qemu-system-x86_64 --enable-kvm -bios /nix/store/qcc1qxnmzg4phgij3ap7v3yq4yhaxiqc-OVMF-2017-12-05-fd/FV/OVMF.fd -device e1000,netdev=net0 -netdev user,id=net0 -m 4G -cdrom /nix/store/i6a4v4jpn1016iipzsqlw9f83a9vh2f7-nixos-18.03.git.06c576b-x86_64-linux.iso/iso/nixos-18.03.git.06c576b-x86_64-linux.iso -hda hdd.img; The actual path for the OVMF bios will change.
  • Ensuring both nixos-install and nixos-enter work, without any warning or weirdness.
Things to do
  • Cherry-pick to 18.03 !

This partially reverts a change from e88f289
which removed the `mount --rbind /sys`.

While true that the activation scripts will mount `sysfs` at `/sys`,
none of the mountpoints lower in the `/sys` tree are handled by the
activation script, which includes `efivarfs`.

This fixes NixOS#38477 since it ensures the presence of `efivarfs` in the
`/sys` tree, which is why the systemd-boot installation failed.
@Mic92 Mic92 requested a review from edolstra April 22, 2018 22:20
@7c6f434c 7c6f434c merged commit 6048470 into NixOS:master Apr 23, 2018
7c6f434c added a commit that referenced this pull request Apr 23, 2018
nixos-enter: Ensures presence of full /sys tree. (for efivarfs)
(cherry picked from commit 6048470)
@samueldr samueldr deleted the fix/nixos-enter-efivarfs branch June 1, 2018 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NixOS 18.03 minimal fails fresh install (systemd-boot-builder)
3 participants