From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id cEEWEHnQgWSm+wAASxT56A (envelope-from ) for ; Thu, 08 Jun 2023 14:58:33 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id aJ9SD3nQgWSpfgEAauVa8A (envelope-from ) for ; Thu, 08 Jun 2023 14:58:33 +0200 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 074FD2FAEF for ; Thu, 8 Jun 2023 14:58:33 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q7FDK-0005qC-Id; Thu, 08 Jun 2023 08:58:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q7FDJ-0005px-Df for bug-guix@gnu.org; Thu, 08 Jun 2023 08:58:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1q7FDG-0004Ox-J2 for bug-guix@gnu.org; Thu, 08 Jun 2023 08:58:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1q7FDG-00078B-Fl for bug-guix@gnu.org; Thu, 08 Jun 2023 08:58:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#53580: shepherd's architecture Resent-From: Csepp Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 08 Jun 2023 12:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 53580 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: attila@lendvai.name, 53580@debbugs.gnu.org X-Debbugs-Original-Cc: Attila Lendvai , bug-guix@gnu.org, 53580@debbugs.gnu.org Received: via spool by 53580-submit@debbugs.gnu.org id=B53580.168622905227357 (code B ref 53580); Thu, 08 Jun 2023 12:58:02 +0000 Received: (at 53580) by debbugs.gnu.org; 8 Jun 2023 12:57:32 +0000 Received: from localhost ([127.0.0.1]:55810 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7FCl-00077A-KM for submit@debbugs.gnu.org; Thu, 08 Jun 2023 08:57:31 -0400 Received: from mx1.riseup.net ([198.252.153.129]:46228) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q7FCi-00076q-VO for 53580@debbugs.gnu.org; Thu, 08 Jun 2023 08:57:30 -0400 Received: from fews02-sea.riseup.net (fews02-sea-pn.riseup.net [10.0.1.112]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx1.riseup.net (Postfix) with ESMTPS id 4QcPPb2hzszDqgm; Thu, 8 Jun 2023 12:57:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1686229043; bh=JSQM68CzUQYEdlDbiVyPJ/50GQI9nB1etrDFYgvQ7fk=; h=References:From:To:Cc:Subject:Date:In-reply-to:From; b=i8mtPhUSGvlvzGjeUI02p11oEsMno1DtZUwFS4YQVshte/8RTWYUpeRwxVLrgPZ/T dHFPj+cJV18MOMpgXJEHCA+3+EFMDu2wqsxa0M9PEq84xBB5x3v8wFrTy9+x3FnaPt dV/YKJYSNcg+713NEKRS6wzlEXV+E/CZv1CknCcw= X-Riseup-User-ID: F74CA7A4E2C2735395224D981A5312C27A7D38C87A13FBEFCC26490C458A3E48 Received: from [127.0.0.1] (localhost [127.0.0.1]) by fews02-sea.riseup.net (Postfix) with ESMTPSA id 4QcPPZ3hXfzFpcn; Thu, 8 Jun 2023 12:57:22 +0000 (UTC) References: <87v8g07ham.fsf@gnu.org> From: Csepp Date: Thu, 08 Jun 2023 14:54:29 +0200 In-reply-to: <87v8g07ham.fsf@gnu.org> Message-ID: <874jnidscx.fsf@riseup.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Seal: i=1; s=key1; d=yhetil.org; t=1686229113; a=rsa-sha256; cv=none; b=czfTTFiUlAPc/r/cKIi6ZqtfcAZsRqwBwl7tL3hJ6fMkcO/Xg8NqezRSLocTFFk4qT0rjt vwEGqxET3LCSLVnGTrDR1ypvanigqkkAIOQHeciYRgd1L/RNA1SsRrCP3BHpJpEn4j6g3C sWEORlW4TQqyBrWT4vGgrC6faSdsMnhPl7nb3pP93tfLSZdkDLcfSFdPIPj+pOZEtIOjk0 eDjsvDUpXn4Vv26mWiQw1Yw6tU7TUm0J08dhZ3mTW0Ilmu1bJqg+jxCiTfJVilVug5StB7 Qhr8Ri2hp/DqCd62FrUaBQroIOaGAQKSuXOIDDqux0e6CCjNt+Mgf4JekderDw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=riseup.net header.s=squak header.b=i8mtPhUS; dmarc=fail reason="SPF not aligned (relaxed)" header.from=riseup.net (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1686229113; 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:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=VahlA0BNHn69qWhed25FMexWQ8VIwwh/NoH8cFX7p0w=; b=EdcArFb/CklyGDQ1uDyjcWEUZnabzCxKHBZ3B666XFpjcoo48GkI46afyfFAXgU2rnHWQJ tTXR/KNGa67CjnPz/qI+WhV0Ww7jKVjUNh2dj7ApAMS9fqBgTDCn867bq+p3+Yu0vtvCQv 4IwIxu9LelJPczsLcOyMJW01D30wvBT5zUmuTihavReWw0GkztxnC57LOaSNftzZ9Yka6d DrQXmdJhAk/JPPxpQvgeHVBFGwEEuHxu6XRX5UuVudbWniRbi28dWo0AW8OJorHShm+jxZ tDHG7QsVXpO9wLU0g5zqSXK03nHrlfOr9eVHy0tfv07MSvEj5om/vA8KCN0c9A== Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=riseup.net header.s=squak header.b=i8mtPhUS; dmarc=fail reason="SPF not aligned (relaxed)" header.from=riseup.net (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Scanner: scn0.migadu.com X-Migadu-Spam-Score: -3.20 X-Spam-Score: -3.20 X-Migadu-Queue-Id: 074FD2FAEF X-TUID: C+3MnmOprGUx Ludovic Court=C3=A8s writes: > Hi Attila, > > Attila Lendvai skribis: > >> [forked from: bug#53580: /var/run/shepherd/socket is missing on an other= wise functional system] >> >>> So I think we=E2=80=99re mostly okay now. The one thing we could do is = load >>> the whole config file in a separate fiber, and maybe it=E2=80=99s fine = to keep >>> going even when there=E2=80=99s an error during config file evaluation? >>> >>> WDYT? >> >> >> i think there's a fundamental issue to be resolved here, and >> addressing that would implicitly resolve the entire class of issues >> that this one belongs to. >> >> guile (shepherd) is run as the init process, and because of that it >> may not exit or be respawn. but at the same time when we reconfigure >> a guix system, then shepherd's config should not only be reloaded, >> but its internal state merged with the new config, and potentially >> even with an evolved shepherd codebase. > > Sorry to be direct: is there a concrete bug you=E2=80=99re reporting here? > >> i still lack a proper mental model of all this to succesfully >> predict what will happen when i `guix system reconfigure` after i >> `guix pull`-ed my service code, and/or changed the config of my >> services. > > What happens is that =E2=80=98guix system reconfigure=E2=80=99 loads new = services into > the running shepherd. New services simply get started; services for > which a same-named service is already running instead get registered as > a =E2=80=9Creplacement=E2=80=9D, meaning that the new version of the serv= ice only gets > started when the user explicitly runs =E2=80=98herd restart SERVICE=E2=80= =99. > > Non-stop upgrades is ideal, but shepherd alone cannot do that. For > instance, nginx supports that, and no init system could implement that > on its behalf. > > Ludo=E2=80=99. Do services get a reference to their previously running version? The Minix project was experimenting with supporting something like supervisor trees for high uptime, and one way they were trying to achieve that was by giving services the memory of their previous version, so they could read their state and migrate it to their own memory.