GNU bug report logs - #39725
/gnu/store/.links: base16 or base32?

Previous Next

Package: guix;

Reported by: Ludovic Courtès <ludo <at> gnu.org>

Date: Fri, 21 Feb 2020 21:52:02 UTC

Severity: normal

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 39725 in the body.
You can then email your comments to 39725 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#39725; Package guix. (Fri, 21 Feb 2020 21:52:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Ludovic Courtès <ludo <at> gnu.org>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Fri, 21 Feb 2020 21:52:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: bug-Guix <at> gnu.org
Subject: /gnu/store/.links: base16 or base32?
Date: Fri, 21 Feb 2020 22:51:28 +0100
Seen while stracing guix-daemon during GC (the “deleting unused links”
phase):

--8<---------------cut here---------------start------------->8---
unlink("/gnu/store/.links/3a16c555c7c60f9c781895eec65a31a04a6cc535fff5a381499c1a4717d8f19f") = 0
unlink("/gnu/store/.links/1mm1n1xmjb1in2sv71kpa90n5iv30h24blzfj4z0icdssbly19kh") = 0
unlink("/gnu/store/.links/4213e7fe3db934f2817fbd0fb3a74e5395736fcc7633d295c557462cae88f945") = 0
unlink("/gnu/store/.links/1g46q6yf868x7wfqnzcy4rb8r780bqi986vjvb1n7xm4ln3jizzf") = 0
unlink("/gnu/store/.links/8b261f0461a89419ee4436d11ac828fc63a4d8d6473696262d020c17758964eb") = 0
unlink("/gnu/store/.links/0znm2gdxraz3i88r3iy838d86s1zfidx8gga4kwiqcsnmaz206d6") = 0
unlink("/gnu/store/.links/f3fe1645f86a6a1effd8e4f0dfcdaef8d73c8163c96d2b2cb42e0bd7c05d9b5b") = 0
unlink("/gnu/store/.links/69a86d84c31d5b728f6d7496413bac8a0bc06c388255f0b81868066463cff80f") = 0
unlink("/gnu/store/.links/0s0bb4pkm282srrdm61fd0lf9zn7r85s370llbp616pk4j2szkhs") = 0
unlink("/gnu/store/.links/a2b0c70e4c03f3247250155d4a2cfdf6a21e03458f892f4c2a9ba861259022f6") = 0
unlink("/gnu/store/.links/5faebd1dc60adbf32b430090a29248b86c56eba4805aeedc8d99c459a28b34eb") = 0
unlink("/gnu/store/.links/8d7d77f86a32f2a0a36b508dcbdc4a44c61dec284b9dc6299a8b7d18db9938dc") = 0
unlink("/gnu/store/.links/1cjlcwkyr59apcym97zaw8r2m4ahqc11zrm51aqzvwg3b0xvchhw") = 0
unlink("/gnu/store/.links/0z9cw4h1p4cm6jp4zap9db1lh60i0ynal0dxd2f8ilzp085wb1xj") = 0
unlink("/gnu/store/.links/1vzgxm1png21gf13v5ac3494h9zshy6y35cxk38pf6dd0qimcand") = 0
unlink("/gnu/store/.links/1r8xm4j57m9h99rvv80q2wgv29p3q42ws4s2f0c3jd9a77hl2qn8") = 0
--8<---------------cut here---------------end--------------->8---

There’s an inconsistency here!

(guix store deduplication) uses base16, but optimize-store.cc does:

    /* Check if this is a known hash. */
    Path linkPath = linksDir + "/" + printHash32(hash);

… where ‘printHash32’ returns a nix-base32 string.  Oops!

The effect is just that deduplication wouldn’t work as well as it could:
results from offloaded builds would be deduplicated among them but not
against other store items.

Ludo’.




Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Sat, 22 Feb 2020 00:01:01 GMT) Full text and rfc822 format available.

Notification sent to Ludovic Courtès <ludo <at> gnu.org>:
bug acknowledged by developer. (Sat, 22 Feb 2020 00:01:01 GMT) Full text and rfc822 format available.

Message #10 received at 39725-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: 39725-done <at> debbugs.gnu.org
Subject: Re: bug#39725: /gnu/store/.links: base16 or base32?
Date: Sat, 22 Feb 2020 01:00:23 +0100
Ludovic Courtès <ludo <at> gnu.org> skribis:

> (guix store deduplication) uses base16, but optimize-store.cc does:
>
>     /* Check if this is a known hash. */
>     Path linkPath = linksDir + "/" + printHash32(hash);
>
> … where ‘printHash32’ returns a nix-base32 string.  Oops!

Fixed in 4cb63a564d413c745983a608790a943ac07f8d67.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 21 Mar 2020 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 8 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.