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

makeself failing to build on Hydra: “Not enough space left in /build (2546273408 KB) to decompress ./makeself-test.run (1 KB)” #110149

Closed
andersk opened this issue Jan 20, 2021 · 7 comments · Fixed by #129338

Comments

@andersk
Copy link
Contributor

andersk commented Jan 20, 2021

Currently the nixos-unstable channel is blocked because nixos.ova is failing due to its dependency nixpkgs.makeself:

Not enough space left in /build (2845170688 KB) to decompress ./makeself-test.run (1 KB)
Use --nodiskspace option to skip this check and proceed anyway
Consider setting TMPDIR to a directory with more free space.
testQuiet:20:Failed
…
Done. 2 passed. 1 failed. 0 skipped.

*** ERROR: Test 'extracttest' failed!

make: *** [Makefile:20: test] Error 1
builder for '/nix/store/h6kp4lp90gqwwxnjy7bp528haid0rbk9-makeself-2.4.2.drv' failed with exit code 2

I haven’t been able to reproduce this locally. The error doesn’t make sense. It seems to come from here:

    leftspace=\`MS_diskspace "\$tmpdir"\`
    if test -n "\$leftspace"; then
        if test "\$leftspace" -lt $USIZE; then
            echo
            echo "Not enough space left in "\`dirname \$tmpdir\`" (\$leftspace KB) to decompress \$0 ($USIZE KB)" >&2
            echo "Use --nodiskspace option to skip this check and proceed anyway" >&2
            if test x"\$keep" = xn; then
                echo "Consider setting TMPDIR to a directory with more free space."
            fi
            eval \$finish; exit 1
        fi
    fi

But plainly 2845170688 is not less than 1, unless there’s a signed 32-bit overflow bug in /bin/sh, which I don’t think there is? Is /bin/sh something wacky on Hydra?

Notify maintainers
@wmertens

Maintainer information:

# a list of nixpkgs attributes affected by the problem
attribute: [makeself]
# a list of nixos modules affected by the problem
module: []
@vcunat
Copy link
Member

vcunat commented Jan 21, 2021

This problem has been appearing randomly for months at least. I had looked into it a bit, but I had no idea what's wrong. A few retries usually work around it.

@andersk
Copy link
Contributor Author

andersk commented Jan 21, 2021

Cc @megastep in case you have any ideas?

@megastep
Copy link

Not really sure, but I'd check what the output of the df command gives you since that's what's used to determine disk space. Maybe the filesystem is reporting this erroneously.

@FRidh
Copy link
Member

FRidh commented Jan 24, 2021

Currently not channel blocking so I changed the label.

@andersk
Copy link
Contributor Author

andersk commented Feb 20, 2021

This has blocked the last two nixos-unstable updates again (among other failures).

@vcunat
Copy link
Member

vcunat commented Jul 5, 2021

So, it really is 31-bit overflow in our default build-time /bin/sh:

$ nix build -f. busybox-sandbox-shell
$ ./result/bin/sh

BusyBox v1.33.1 () built-in shell (ash)

$ test 2845170688 -lt 1; echo $?
0

@vcunat vcunat closed this as completed in faaa3bc Jul 5, 2021
github-actions bot pushed a commit that referenced this issue Jul 5, 2021
Hopefully fixes #110149.  I'm really annoyed with this on 21.05 now:
https://hydra.nixos.org/build/147005675#tabs-buildsteps
and this isn't the first time it's caused significant issues.

(cherry picked from commit faaa3bc)
@vcunat vcunat reopened this Jul 5, 2021
vcunat added a commit to vcunat/nixpkgs that referenced this issue Jul 6, 2021
I couldn't find an easy way to work around this while doing the tests,
so let's disable them for now and work on fixing the sandbox shell
instead (and re-enable tests after that is deployed; I hope).
@vcunat
Copy link
Member

vcunat commented Jul 6, 2021

... and cross-ref to upstream: https://bugs.busybox.net/show_bug.cgi?id=13926

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants