From mboxrd@z Thu Jan 1 00:00:00 1970 From: zimoun Subject: Re: prevent gc of texlive-...-texmf.tar.xz Date: Wed, 12 Feb 2020 19:08:31 +0100 Message-ID: References: <20200212.135345.176088053800652108.post@thomasdanckaert.be> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:50605) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j1wRI-0006id-Fu for help-guix@gnu.org; Wed, 12 Feb 2020 13:08:46 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j1wRH-0006kp-6Y for help-guix@gnu.org; Wed, 12 Feb 2020 13:08:44 -0500 Received: from mail-qv1-xf2d.google.com ([2607:f8b0:4864:20::f2d]:42802) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j1wRH-0006kN-11 for help-guix@gnu.org; Wed, 12 Feb 2020 13:08:43 -0500 Received: by mail-qv1-xf2d.google.com with SMTP id dc14so1339702qvb.9 for ; Wed, 12 Feb 2020 10:08:42 -0800 (PST) In-Reply-To: <20200212.135345.176088053800652108.post@thomasdanckaert.be> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane-mx.org@gnu.org Sender: "Help-Guix" To: Thomas Danckaert Cc: help-guix Hi, On Wed, 12 Feb 2020 at 13:54, Thomas Danckaert wrote: > I have limited space on my root file system, and therefore need to > run 'guix gc' regularly. One problem with that is that the texlive > source package (currently > /gnu/store/mj40l554qxw15acz0h018gk5c9mxzfgn-texlive-20180414-texmf.tar.xz) > regularly gets deleted that way. When I upgrade after running guix > gc, I often find I need to download this very large (2.5G) tarball > again. What does it mean "upgrade after running guix gc"? If 'texlive' is installed in a profile, "guix gc" cannot delete it. Or I miss a point. Do you mean that you work only with temporary profile ("guix environment") and you garbage collect each time you have ended with this temporary profile and you create often the same temporary profile (say '--ad-hoc texlive')? Is it what you mean? However, note that 'texlive' could even be downloaded twice, I guess, --8<---------------cut here---------------start------------->8--- $ guix package -i texlive -p /tmp/texlive substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0% substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0% The following package will be installed: texlive 20180414 /gnu/store/wlba9v03ypi0z5qz7p89sa0w12lh37zb-texlive-20180414 substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0% The following derivations will be built: /gnu/store/4zlvfr2qv4ky1r7ski9inpaixqx7ingz-profile.drv /gnu/store/2s9f925wx29p75i6yzv3svki6ldb3ngp-texlive-texmf-20180414.drv 2,595.2 MB will be downloaded: /gnu/store/5aq60gx42sfs5drigb5g7fpa7fh1pq4z-texlive-20180414 /gnu/store/mj40l554qxw15acz0h018gk5c9mxzfgn-texlive-20180414-texmf.tar.xz The following grafts will be made: /gnu/store/al6wnvipcns3pkz4d9j1xg40cf9vg9qh-texlive-20180414.drv /gnu/store/3jpxlpgjabr5ilrn8pisl07sl2vsns7a-texlive-texmf-20180414.drv The following profile hooks will be built: /gnu/store/03ry4vji3qz300wbx2a71bq6bilx2c50-ca-certificate-bundle.drv /gnu/store/cbjz3ydan5ach8vzcbmvwa92zqb4f0nn-manual-database.drv /gnu/store/i5j5896wcslgrz6nx8jd8hfw50qkwkhw-fonts-dir.drv /gnu/store/kik4kvwv7s3hpb0k5sbzv3dc97fwh1bb-info-dir.drv downloading from https://ci.guix.gnu.org/nar/mj40l554qxw15acz0h018gk5c9mxzfgn-texlive-20180414-texmf.tar.xz... texlive-20180414-texmf.tar.xz 2.42GiB 10.2MiB/s 04:03 [##################] 100.0% downloading from https://ci.guix.gnu.org/nar/lzip/zkcd3i5r98rh36cp9is1l5griiyrgvap-texlive-texmf-20180414... texlive-texmf-20180414 2.38GiB [...] --8<---------------cut here---------------end--------------->8--- > How do I add a gc root for this tarball (or is that a bad idea)? I > tried 'guix build texlive --source --root ...', but I get a warning > 'package texlive has no source'. A quick workaround could be to create your own channel containing for example this definition: --8<---------------cut here---------------start------------->8--- (define-public my-texlive (package (inherit texlive) (version "mine") (source (origin (method url-fetch) (uri "file:////your/local/path/to/texlive-20180414-texmf.tar.xz") (sha256 (base32 "xxxx")))))) --8<---------------cut here---------------end--------------->8--- So, you download once the texlive archive and you locate it somewhere on your local disk. Then each time, you run "guix install texlive@mine", Guix will compute the derivations etc. and will fetch the source directly from your local disk. It does not answer your question for protecting from GC but it should avoid to download it again and again when you did a mistake with "guix gc". Hope that helps, simon