Skip to content

NixOS Tests broken in master and staging #96197

@jonringer

Description

@jonringer

Describe the bug
Trying to build a nixosTests fails due to stage-1 failing during creation of extra-utils

builder for '/nix/store/z1cxv06bi8iihhcifik0aqllqdbxhwpi-extra-utils.drv' failed with exit code 1
cannot build derivation '/nix/store/h8zxyl8r36bl4av33l2fbq0wkjs775mi-stage-1-init.sh.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/dbl58yvryaxsd4qzmxc09z4npzl07m7s-initrd-linux-5.4.54.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/qr9hy73gr3wwgk81ll2f063ry57idlk2-nixos-system-bbmaster-20.09.git.4cfd81acfa0M.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/rylgj77220s22979zlasdyrmw6g4syvf-nixos-system-bbworker-20.09.git.4cfd81acfa0M.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/6hss4221vbsch61ka9pzpsw2sfhh3lcg-nixos-system-gitrepo-20.09.git.4cfd81acfa0M.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/5sfqhjd1jsbf117sjn70ik777b03lqhi-nixos-vm.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/kah87whvjpp1zxqgjikwwny0249idlgb-nixos-vm.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/sxlb9fh7fqylpzw96jlkg4kfd2nrwshm-nixos-vm.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/xghh70sibzsnw27amzjrli0mgrx39f9j-nixos-test-driver-buildbot.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/4riphbxaqq2ql1kw0nfv8yhiiv08xjbx-vm-test-run-buildbot.drv': 1 dependencies couldn't be built

nix log:

Copying libs for executable /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/lib/ld-linux-x86-64.so.2
/nix/store/ljd94dg6vmw9lx4vkszvl109w9y164sg-find-libs/bin/find-libs: line 19: left: unbound variable
stripping (with command strip and flags -s) in /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/lib  /nix/store/75p0>
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/systemd-sysctl...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/dmsetup...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/systemd-udevd...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/v4l_id...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/busybox...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/udevadm...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/ata_id...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/mke2fs...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/lvm...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/e2fsck...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/blkid...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/cdrom_id...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/mdadm...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/fido_id...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/tune2fs...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/kmod...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/scsi_id...
patching /nix/store/75p0yg2l7lciimfjm6hdh67rl6lyy99i-extra-utils/bin/mdmon...
testing patched programs...
hello world
245

from my own trouble shooting, the erring block of code is this "initrd test block"

$out/bin/ash -c 'echo hello world' | grep "hello world"

To Reproduce

git checkout staging # or master
git pull
nix-build -A nixosTests.buildbot

Expected behavior
able to run tests successfully

Additional context
git bisect run nix-build -A nixosTests.buildbot pointed me to:

72c8ed038946850d345db13f30e259a368d7c3c5 is the first bad commit
commit 72c8ed038946850d345db13f30e259a368d7c3c5
Author: Florian Klink <[email protected]>
Date:   Mon Aug 19 02:08:46 2019 +0200

    systemd: build with cryptsetup and cryptsetup-generators

    There's a circular dependency to systemd via cryptsetup and lvm2
    (systemd -> cryptsetup -> lvm2 -> udev=systemd).

    However, cryptsetup only really needs the devmapper component shipped
    with lvm2. So build `pkgs.cryptsetup` with a lvm2 that doesn't come with
    udev.

 nixos/modules/system/boot/systemd.nix      | 2 +-
 pkgs/os-specific/linux/systemd/default.nix | 4 +++-
 pkgs/top-level/all-packages.nix            | 6 +++++-
 3 files changed, 9 insertions(+), 3 deletions(-)

but this could be misleading due to how staging git history works

Notify maintainers
cc @flokli

Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.

 - system: `"x86_64-linux"`
 - host os: `Linux 5.4.60, NixOS, 20.09.git.2710fed815aM (Nightingale)`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.3.7`
 - channels(archlayperson): `"home-manager"`
 - channels(root): `"nixos-20.09pre239318.c59ea8b8a0e"`
 - channels(jon): `"home-manager, nixos-20.09pre239318.c59ea8b8a0e"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`

Maintainer information:

# a list of nixpkgs attributes affected by the problem
attribute: nixosTests
# a list of nixos modules affected by the problem
module:

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bugSomething is broken1.severity: channel blockerBlocks a channel6.topic: module systemAbout "NixOS" module system internals6.topic: nixosIssues or PRs affecting NixOS modules, or package usability issues specific to NixOS6.topic: testingTooling for automated testing of packages and modules

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions