Open deliciouslytyped opened 5 years ago
This is causing the problem, http://nixos.org/tarballs
redirects to https before the tarballs.nixos.org redirect resulting in a https request while the bootstrap build can't fetch that yet.
/cc @grahamc
since (sadly imo) nixpkgs only really accepts one version of a package at a time
This is not true. We are fine with multiple versions of single package, as long as there is good enough reason to keep the old one. Most of the time there is not any, so the concerns about maintenance costs of extra packages and security issues of ancient code prevail.
(Yeah, my bad, I knew better and yet I still said that. I'm tired.
I would like it if version hopping across already created scripts wasn't possibly only through the git history, but I can understand that there would be problems with that under the current model. I would still like it if it was possible eventually.)
Keeping all version in-tree would require some kind of policy for choosing the moment we give up on updating the deps.
Maybe if it is a problem only with stdenv
, we should just document how to get the list of things to fetch, and how to prefetch them using a fresh Nixpkgs checkout?
@7c6f434c To be fair, currently the problem seems to be a matter of the old sha256 interface having been removed or somesuch / the cache being reorganized. Though in the theoretical case that sha256 is insecure I'm not sure what to do about that.
I'd be quite happy if it was just a documentation problem, if it's a solution that's still reasonably viable for a user.
However currently what I did, was I had to run through the build process numerous times to collect the names of the failing fetches, and then google for the archives, and add them using --add-fixed
I've run into a new failure while building util-linux-ng
chmod: changing permissions of '/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin/mount': Operation not permitted
in
make[2]: Entering directory `/build/util-linux-ng-2.18/mount'
building install-binPROGRAMS
test -z "/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin" || /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/mkdir -p "/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin"
/bin/sh ../libtool --mode=install /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c mount umount '/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin'
libtool: install: /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c .libs/mount /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin/mount
138: Trace output ok
libtool: install: /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c .libs/umount /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin/umount
building install-sbinPROGRAMS
test -z "/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin" || /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/mkdir -p "/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin"
/bin/sh ../libtool --mode=install /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c losetup swapon '/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin'
libtool: install: /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c losetup /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin/losetup
libtool: install: /nix/store/7w8b9g33z1vffv6y2swr3dbiddsrysdl-coreutils-8.7/bin/install -c .libs/swapon /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin/swapon
building install-exec-am
make install-exec-hook
make[3]: Entering directory `/build/util-linux-ng-2.18/mount'
building install-exec-hook
cd /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/sbin && ln -sf swapon swapoff
chmod 4755 /nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin/mount
chmod: changing permissions of `/nix/store/wg33bxhbdnb9hl6asn6gxwrnzfjhdv3w-util-linux-ng-2.18/bin/mount': Operation not permitted
make[3]: *** [install-exec-hook] Error 1
make[3]: Leaving directory `/build/util-linux-ng-2.18/mount'
make[2]: *** [install-exec-am] Error 2
make[2]: Leaving directory `/build/util-linux-ng-2.18/mount'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/build/util-linux-ng-2.18/mount'
make: *** [install-recursive] Error 1
builder for '/nix/store/86jim6yp6kj3p6rqq7apqablida8q094-util-linux-ng-2.18.drv' failed with exit code 2
@7c6f434c To be fair, currently the problem seems to be a matter of the old sha256 interface having been removed or somesuch / the cache being reorganized. Though in the theoretical case that sha256 is insecure I'm not sure what to do about that.
Arguably, there are multiple issues.
It would be nice to have a published policy for retention/resource management in binary cache, as well as in tarball cache. I frankly have no idea if failure to grab from binary cache is a misconfiguration on your part, a weird effect of long-term compatibility or just the file having been finally garbage-collected. The same question but separately — about tarball cache.
One could try to fetch from upstream URLs; even if they were already HTTPS and unaccessible to bootstrap curl, we could write a script to export a list of urls and just prefetch them.
1a. We do not always write the list of URLs correctly, i.e. in a way that takes into account upstream policies on moving old sources to a slower archive mirror.
2a. If sha256 is insecure and sha256-addressing is retired, it is possible to have a script with all correspondences between old SHA256 URLs and whatever new scheme for tarballs is supported (for tarballs that are retained, see point 0).
I think we should separate this out into an appropriately named issue, or rename the current one, do you have any ideas?
I thought your plan for the current issue was to discuss and hopefully work around all the issues arising from zero to Eclipse. I also replied by mail without checking for updates, sorry.
What is your current preferred use/goals for this issue?
Yeah you're right but this more general than my specific problem, but we can continue here, that's fine for me.
Well, I can only hope there are not additional fetching problems to arise… Otherwise I hoped this could be useful for triage, too. If I decide to continue in general, I will create specific issues.
(In hindsight, I have no idea why I thought sha256 is being deprecated for sha512...is it?)
Not actively yet.
Thank you for your contributions.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:
I didn't think I'd end up running into https://github.com/NixOS/nixpkgs/issues/55588, https://github.com/NixOS/nixpkgs/issues/53653 ,
but the recently released ghidra wants a really old version of eclipse for its ghidraDev plugin(edit: misunderstood an error). I figured I could try getting an old version of eclipse from an old version of nixpkgs, since (sadly imo) nixpkgs only really accepts one version of a package at a time.Building off an old github release like the following yields the pasted errors:
By @LnL7 's advice, I used
nix-store --add-fixed sha256 <path>
(which is now documented with https://github.com/NixOS/nix/pull/2724) to add that archive, and other archives that were missing with later similar errors:There's an HTTPS redirect there which is the original problem, but if you try to resolve the tarballs url in the browser you also run into a 404.
edit: correction about ghidraDev wanting an old eclipse, I misunderstood an error