From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cMkXE1VVmWANFQEAgWs5BA (envelope-from ) for ; Mon, 10 May 2021 17:46:29 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id gDG9DlVVmWB+LQAAB5/wlQ (envelope-from ) for ; Mon, 10 May 2021 15:46:29 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E5B8024308 for ; Mon, 10 May 2021 17:46:28 +0200 (CEST) Received: from localhost ([::1]:39482 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lg872-0007oC-2o for larch@yhetil.org; Mon, 10 May 2021 11:46:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54736) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lg86J-0007lq-VU for guix-devel@gnu.org; Mon, 10 May 2021 11:45:46 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:43660) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lg86I-0007ke-MV; Mon, 10 May 2021 11:45:42 -0400 Received: from 2001-1c02-0b18-2900-222e-248e-9586-e52d.cable.dynamic.v6.ziggo.nl ([2001:1c02:b18:2900:222e:248e:9586:e52d]:35334) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lg86G-00044c-WE; Mon, 10 May 2021 11:45:42 -0400 Message-ID: <7c642c5ca7a0986e6877cdefb6b1f872942f03ba.camel@gnu.org> Subject: Re: =?UTF-8?Q?=E2=80=9Cguix?= =?UTF-8?Q?_gc=E2=80=9D=2C?= auto gcroots, cluster deployments From: Roel Janssen To: Ricardo Wurmus Date: Mon, 10 May 2021 17:45:30 +0200 In-Reply-To: <87a6p2pzok.fsf@elephly.net> References: <87im3qq57z.fsf@elephly.net> <3795a0268fd5e90b6e1bac171bca97693d8a721d.camel@gnu.org> <87a6p2pzok.fsf@elephly.net> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.40.1 (3.40.1-1.fc34) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: guix-devel@gnu.org Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1620661589; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=4vI37W7GFvB4FDoJaO/4DymujZ9feYkTZfC1UQ0GRJI=; b=C5t5/V5//b8uPn6UwFMI9D5qOOwlfK2+CLGPtS6Ow09mH67EpF+vh4KymfMLv6/5NvbmFO cuSuYhIaDLhEFzSff+9J8uRKm3iI7L8LnGsrwfFJcsJ4+U0orsqeDwVwE+l63iQMNZARx4 5DqlMhyNwx7LtEkiesuMPEqhr6VOWZIUIQV5K7+v+Pky+QgGWWKvnYTT36Ml++qok+WJQ1 uaAus/64Vf+jabfi2/8hAxDGwe0ScmZ3O+Cc175aFYjrcu/ZKitLSRjO+f7VRAKOnITNty 1Gbn2TH0E3ZClJi4VI2vuNpmsShuiUG/otWBFfjbmrnouajUDaxTVEJXny3d1A== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1620661589; a=rsa-sha256; cv=none; b=chhJKQRZfuKhD/m92cDF8jw/oEw3IUMogc7i/f9EAUSC+/dJwyZ9rUdD/D2y8BQDHkInr/ aCf0OkMoWvQAMaaWKvfCnO9uQQnY4eNMjq0HiumnP2AmUD0nP2xWO12GlC9LdaFao0gnor r4AT9GUuXtVrJyhR9jEdwTSsxlrp2eY/Czsep0fQlDkaJlaaF6hut/1DseGfy24kZOOFxE II3vR8/M6zAEyuM5wgu1wBziaYbIaRZF+1lhbp7OwfRvpmRpCvElVcknjUxbVPxEYOr5mm DXxEFZH3TOe3zlyfuFp8u+cxIiYHSb7+/V9A+w53IHp4dN7IxcITAQO4+VBcjw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Spam-Score: -2.95 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Queue-Id: E5B8024308 X-Spam-Score: -2.95 X-Migadu-Scanner: scn0.migadu.com X-TUID: a94Ec+ZDC7D1 On Mon, 2021-05-10 at 13:59 +0200, Ricardo Wurmus wrote: > > Hi Roel, > > thanks for your feedback! > > > Would it be possible to add an option to retrospectively apply > > this > > transformation?  Maybe that could work somewhat like this: > > > > $ ls -lha > > ... /home/me/projects/mrg1_chipseq/.guix-profile-1-link -> > > /gnu/store/ap0vrfxjdj57iqdapg8q83l4f7aylqzm-profile > > This wouldn’t work, because we can’t read > /home/me/projects/mrg1_chipseq/.guix-profile-1-link centrally.  In > this particular case only the user “me” could resolve the link and > thus migrate the link.  (I would do this semi-manually by > impersonating the users to read their links.) > Indeed we cannot resolve /home/me/projects/mrg1_chipseq/.guix-profile- 1-link as another user than "me". So "me" would have to run the hypothetical "guix gc --synchronize-profiles-to-gcroots". >From my point of view, that would be fine. We can simply ask the users on the cluster to execute that command once. This could work if we have a mechanism to determine how complete the garbage-collection picture for "root" is, and only continue GCing when the picture is complete. A starting point for this is $localstatedir/gcroots/auto which provides an overview of all profiles that have been created. Perhaps we can reuse the filename of the symlink. So in the example given in the previous e-mail we could add another link like so, but in a different directory: 8ypp8dmwnydgbsgjcms2wyb32mng0wri -> /gnu/store/...-profile For which this already existed in $localstatedir/gcroots/auto: 8ypp8dmwnydgbsgjcms2wyb32mng0wri -> /home/me/projects/mrg1_chipseq/.guix-profile-1-link And then a one-time transition can be made by looking up 8ypp8dmwnydgbsgjcms2wyb32mng0wri in both places. Maybe I'm making things needlessly complex, but I would really like a solution that can be applied to an existing cluster setup. :) So, your initial proposal sounds good to me already. How it could be made more useful for the retrospective matching of unreachable symlinks to /gnu/store paths can be considered a separate issue to solve. > ~ ~ ~ > > Another related problem I found is that the names of the links in > unreadable space may have names that only make sense on the system > where they were created.  For example, on the server “beast” we > may mount the cluster home directory as “/clusterhome/me”, whereas > on cluster nodes it would be mounted as “/home/me”.  When I have > Guix record a gcroot while working on “beast” I would get a link > that is no longer valid when I work on the cluster. > Yes, I agree that this is another reason to implement your suggested change. :) Kind regards, Roel Janssen