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
zfs: fix zfs legacy mount #111375
zfs: fix zfs legacy mount #111375
Conversation
a019abe
to
5794ba8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just tried to build this but something is going wrong.
hash mismatch in fixed-output derivation '/nix/store/qg2803fwr0fvg6k2cdvb58vm4ggkh2f6-03f036cbccdd8699f5fe8540ef317595a35bceb8.patch.drv':
specified: sha256-grrxQdmoUgpFpzYtSP7c2tLhQn+gmFwl06+VCqlHVyw=
got: sha256-wVe7tlUaTnIMP6ugBeG3LkaS0wTG/14OaFaRvUcZfco=
Hmm weird, just tried it again (
which outputs this:
|
I simply ran nix-shell -p nixpkgs-review --run "nixpkgs-review pr --no-shell --post-result 111375" EDIT: I checked the store path and indeed, the patch header seems to be missing. Instead of a patch I only got a diff, so this might be a problem on GitHub's side. I'm deleting the store paths right now and then retry. |
I checked out your branch and tried to build a single derivation but it still fails. $ git log -1
commit 5794ba8b652b862f19b0662acb7dabe37c0535ef (HEAD -> fix-zfs-path-sanitizer-patch, refs/nixpkgs-review/1)
Author: Philipp Mildenberger <philipp.mildenberger@koeln.de>
Date: Sun Jan 31 02:00:06 2021 +0100
zfs: fix zfs legacy mount
Closes #110376
$ nix-build -A zfs
these 2 derivations will be built:
/nix/store/qg2803fwr0fvg6k2cdvb58vm4ggkh2f6-03f036cbccdd8699f5fe8540ef317595a35bceb8.patch.drv
/nix/store/xnmc86mn26idv3gjhyc2gjn52vfn5hhh-zfs-user-2.0.1.drv
building '/nix/store/qg2803fwr0fvg6k2cdvb58vm4ggkh2f6-03f036cbccdd8699f5fe8540ef317595a35bceb8.patch.drv'...
trying https://github.com/openzfs/zfs/commit/03f036cbccdd8699f5fe8540ef317595a35bceb8.patch
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3594 100 3594 0 0 18151 0 --:--:-- --:--:-- --:--:-- 18060
error: --- Error --- nix-daemon
hash mismatch in fixed-output derivation '/nix/store/qg2803fwr0fvg6k2cdvb58vm4ggkh2f6-03f036cbccdd8699f5fe8540ef317595a35bceb8.patch.drv':
specified: sha256-grrxQdmoUgpFpzYtSP7c2tLhQn+gmFwl06+VCqlHVyw=
got: sha256-wVe7tlUaTnIMP6ugBeG3LkaS0wTG/14OaFaRvUcZfco=
error: --- Error -------------------------------------------------------------------------------------- nix-build
1 dependencies of derivation '/nix/store/xnmc86mn26idv3gjhyc2gjn52vfn5hhh-zfs-user-2.0.1.drv' failed to build Maybe somebody else can reproduce. Here is the output of
|
Maybe it helps to compare the patches itself, this is the content of the url when I access it: Is there a more reproducable way to access patches in github? |
no, this is because fetchpatch will do some normalization before saving it to the store path, thus it changes the sha.
change the sha to something invalid, I usually just change something to an "a". and run the build again, the expression will then be evaluated, instead of referencing an existing store path.
|
5794ba8
to
c67f9d2
Compare
Thanks, something new learned again. |
there was an attempt to make the fixed-output-derivations a little more ergonomic in NixOS/rfcs#84 . However, once you make a content addressed derivation more than just it's content.... then you have issues when you want to have alternate sources, and a few other issues. For now, the rule of thumb is just to make the sha invalid, and take what nix says it wanted. As there's also other issues like if the content is packed or unpack (fetchFromGithub will unpack the source) which will also not align with |
Result of 1 package marked as broken and skipped:
3 packages failed to build:
59 packages built:
|
do we need a backport? |
Closes #110376
See related discussion
Things done
Apply the following patch from ZFS upstream: openzfs/zfs@03f036c
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)