From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id BgsCJz/CK2DSTwAA0tVLHw (envelope-from ) for ; Tue, 16 Feb 2021 13:01:51 +0000 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id sNEpIj/CK2DWWgAAbx9fmQ (envelope-from ) for ; Tue, 16 Feb 2021 13:01:51 +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 D2C1118881 for ; Tue, 16 Feb 2021 14:01:50 +0100 (CET) Received: from localhost ([::1]:41842 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lBzzB-0002q3-Rr for larch@yhetil.org; Tue, 16 Feb 2021 08:01:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35258) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lBzyQ-0002VP-SF for guix-patches@gnu.org; Tue, 16 Feb 2021 08:01:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:56446) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lBzyQ-0000Ob-1a for guix-patches@gnu.org; Tue, 16 Feb 2021 08:01:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lBzyP-0001Ag-VJ for guix-patches@gnu.org; Tue, 16 Feb 2021 08:01:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#46560] [PATCH 0/2] Activate system when switching generations. Resent-From: Brice Waegeneire Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 16 Feb 2021 13:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 46560 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 46560@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16134804554085 (code B ref -1); Tue, 16 Feb 2021 13:01:01 +0000 Received: (at submit) by debbugs.gnu.org; 16 Feb 2021 13:00:55 +0000 Received: from localhost ([127.0.0.1]:39759 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lBzyI-00013d-Q6 for submit@debbugs.gnu.org; Tue, 16 Feb 2021 08:00:55 -0500 Received: from lists.gnu.org ([209.51.188.17]:42692) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lBzyG-00011T-Kc for submit@debbugs.gnu.org; Tue, 16 Feb 2021 08:00:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35128) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lBzyG-0002Rd-Ag for guix-patches@gnu.org; Tue, 16 Feb 2021 08:00:52 -0500 Received: from relay10.mail.gandi.net ([217.70.178.230]:37045) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lBzyD-0000HQ-Ia for guix-patches@gnu.org; Tue, 16 Feb 2021 08:00:51 -0500 Received: from localhost (reverse4.evolix.net [31.170.9.129]) (Authenticated sender: brice@waegenei.re) by relay10.mail.gandi.net (Postfix) with ESMTPSA id 55E5C240017 for ; Tue, 16 Feb 2021 13:00:42 +0000 (UTC) From: Brice Waegeneire Date: Tue, 16 Feb 2021 13:35:46 +0100 Message-ID: <87czx06ubt.fsf@waegenei.re> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=217.70.178.230; envelope-from=brice@waegenei.re; helo=relay10.mail.gandi.net X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -0.86 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: D2C1118881 X-Spam-Score: -0.86 X-Migadu-Scanner: scn0.migadu.com X-TUID: 3trBK20077jq Hello, As reported on previous bug report, rolling-back or switching generation doesn't activate the system as a system reconfiguration would do. This is especially problematic when modifying in /run/setuid-programs, as it can't be reverted easily. Also it hinder modification in the activation script since it's not straight forward to revert change made by those script without a functional roll-back mechanism. I'm not sure it's the right approach but at least it work: it add the activate.scm script to the system profile and then load it when switching-generation. This is related to issues: - #37596 and #38884 (they are duplicate) - #36855 a more wider discussion Cheers, - Brice Brice Waegeneire (2): gnu: services: Add activate script to the profile system directory. scripts: system: Activate system when switching generations. gnu/services.scm | 10 +++++++++- guix/scripts/system.scm | 8 ++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) -- 2.30.1