From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id EKQhOS5pY2fddwAAqHPOHw:P1 (envelope-from ) for ; Thu, 19 Dec 2024 00:30:39 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id EKQhOS5pY2fddwAAqHPOHw (envelope-from ) for ; Thu, 19 Dec 2024 01:30:39 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b="IBthJ/Mx"; dkim=fail ("headers rsa verify failed") header.d=wolfsden.cz header.s=mail header.b="Q/BuqrPI"; dkim=fail ("headers rsa verify failed") header.d=wolfsden.cz header.s=mail header.b="Q/BuqrPI"; 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"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=wolfsden.cz (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734568238; 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: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=pcqzpSsJ4MYAHkpgdTaO8JM1Fvm3vM2FakcYPchjO2c=; b=nu/DQ/HTSgGLzf/beWmesDvI1Lq/N+ZLQt2Bozb6+5GmD6D0sOH9ZXrWTJiq04xhvTD9bB OXUL7jZ65uvW7OJQwIKsAPYU1KZ6X/QhPncruhg7qQQY5POIwGvnLuNPELLsoGJam18ukN dxGzSODvYCwF1CDUZ/yK7/8m47FosDFMFr9YotCz1vP7wBSgT3xD72ge66Kc8+jYkPBzpg Hj4PXx3a8gx+rR73cmVDXmrr4NiuLFpuXzAr2gdbgAjd/Qpv2U0omKmktbWaKps5AvFS8A fOd0IEsqNrPc2mBktzClC3M0WchfpiQ7SjrENa9UzmdpyEAeWdf97PpXZHWkjQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b="IBthJ/Mx"; dkim=fail ("headers rsa verify failed") header.d=wolfsden.cz header.s=mail header.b="Q/BuqrPI"; dkim=fail ("headers rsa verify failed") header.d=wolfsden.cz header.s=mail header.b="Q/BuqrPI"; 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"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=wolfsden.cz (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734568238; a=rsa-sha256; cv=none; b=rekf4+Mq1oy8O39sBaeWVl6YA7+jWgTI5fPfR1WClDVgLzEtfEtwNO9ZdMzyotpdlUwacp t7V/ocjV08izvUuDde8E9jweUulvoa6GWrIY/eBujnADNF3e5JTfw8Ud1xokXf3qMGbwYX qHkrGJURjKsGtVLqNXx3KTNCllyJfFCOttDKm2mcW9dyo8We2crmzxi1thMyqO6RbpcZuk aGHiR03TpMeJKg+qmMi54iKyIkkChfg7fiiXlg+HRIdinNvMl4QL20jACv5SSOrrPG7J16 hgEyuuP9xytbRhu6xWr/BycLIz5MTIdmN5tzfVDO2LbvZ8xEptIzmUlI9tTeFg== 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 3B2DE7898C for ; Thu, 19 Dec 2024 01:30:37 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tO4Qg-0002ff-0H; Wed, 18 Dec 2024 19:30:14 -0500 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 1tO4QU-0002a3-Sb for bug-guix@gnu.org; Wed, 18 Dec 2024 19:30:03 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tO4QU-0000A6-Iv for bug-guix@gnu.org; Wed, 18 Dec 2024 19:30:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=pcqzpSsJ4MYAHkpgdTaO8JM1Fvm3vM2FakcYPchjO2c=; b=IBthJ/MxIUIv9LKYImrehHFW+pyD159lSyXgMH/BusmDpv3mzgl0WX7ZpEDuu7qtw/HwdEnc4wFyStIYDVlJfDxYQD+OWwMerG43pq239rLJKP3FYrt1E9VOBw4fz3B19fxq7j/0Puv/2q+fjICrmd9+8DGSk7m1XaELXOQSmEJ8eT8c3h9vR9vHiEjMYsyM62cnYJ6w/2nG4QniJgJHtn6wYUjCpymqMGh8OYR7S9tKj8Dg2TXY1QTaQdlOTbuiSPtAS5CbfBEmtXuDtswLnRe6MdEVuEsn4l4FunpNjFi9reG1Dr+mfahug20zLLSuMZj1Itt/8ULfPIwvpdAprg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tO4QU-0002X2-B4 for bug-guix@gnu.org; Wed, 18 Dec 2024 19:30:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#74912: Shepherd: Growing number of user shepherds when relogging Resent-From: Tomas Volf <~@wolfsden.cz> Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 19 Dec 2024 00:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74912 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: Jake , 74912@debbugs.gnu.org Received: via spool by 74912-submit@debbugs.gnu.org id=B74912.17345681599638 (code B ref 74912); Thu, 19 Dec 2024 00:30:02 +0000 Received: (at 74912) by debbugs.gnu.org; 19 Dec 2024 00:29:19 +0000 Received: from localhost ([127.0.0.1]:36550 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tO4Pm-0002VO-I9 for submit@debbugs.gnu.org; Wed, 18 Dec 2024 19:29:18 -0500 Received: from wolfsden.cz ([37.205.8.62]:46720) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <~@wolfsden.cz>) id 1tO4Pk-0002VC-4E for 74912@debbugs.gnu.org; Wed, 18 Dec 2024 19:29:17 -0500 Received: by wolfsden.cz (Postfix, from userid 104) id 9052F37DBB9; Thu, 19 Dec 2024 00:29:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1734568154; bh=QrleOTR7HkLmXyMY7EvkqpLIB/tllFWPe/k26YXf2mw=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=Q/BuqrPIUuduFtsg6umOYuExftstODkdAK3GvzxN87f3ZU6FRibiYSzXGJwHGtPl9 qa/iQhTemasMDRt8b0vJTaji5wjmb6/7HqHfIRtcEiSmHXoRMeUrf9SOt0QiqSvMLi MiH4dKCo8VjZfBkXVOKM2ZWVfveSalOti1Ngpk9LAAxW/kuYA1dQPyGaYpZj36Y7JX 3vk5BZJVVWfJvjSycW1Jr6GucaE87Is3bQk04MU8nvGgkRRomof8R3POGP13dnZfX+ ihL7r9JoRxeiq10DQIpABEQF0E8TTFTHUUo1oPgU7C2+Xar1Rs7H0GEIj0EPyhFUBe eqDrBsVLgFut3xfl7ihXDl6shH7Fl7zZ2kpq38VrPCfq4YqL3pljrj7wkI1DIDow+o 88RARSzcBmK35K1moGNVau/uesR9hBFSB2h6SN37Vo8s9tb0W6i61LUoREfYus1HfX sw3TJLgQsmcrv5nyubP6aql5et1d+ma2GD2LGoqY7iduOuKgndI5ZfXSOkBgIHYmvK GDQ0W4VpVIt4Ud6QQoPpKDCMFlapTjrTbkO33i2fuU5B/eHGXW/16vW8+NRi/Px7K0 wTa/wW0Gz6KkrDXzIrjAEoFyAbAEaXqwVKsrhXKuT6xLturVxkrwe1CTbuyA0eYL9Y NveX++5nacyS67bhq9MOilYs= Received: from localhost (unknown [128.0.188.242]) by wolfsden.cz (Postfix) with ESMTPSA id 21A0137E094; Thu, 19 Dec 2024 00:29:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1734568154; bh=QrleOTR7HkLmXyMY7EvkqpLIB/tllFWPe/k26YXf2mw=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=Q/BuqrPIUuduFtsg6umOYuExftstODkdAK3GvzxN87f3ZU6FRibiYSzXGJwHGtPl9 qa/iQhTemasMDRt8b0vJTaji5wjmb6/7HqHfIRtcEiSmHXoRMeUrf9SOt0QiqSvMLi MiH4dKCo8VjZfBkXVOKM2ZWVfveSalOti1Ngpk9LAAxW/kuYA1dQPyGaYpZj36Y7JX 3vk5BZJVVWfJvjSycW1Jr6GucaE87Is3bQk04MU8nvGgkRRomof8R3POGP13dnZfX+ ihL7r9JoRxeiq10DQIpABEQF0E8TTFTHUUo1oPgU7C2+Xar1Rs7H0GEIj0EPyhFUBe eqDrBsVLgFut3xfl7ihXDl6shH7Fl7zZ2kpq38VrPCfq4YqL3pljrj7wkI1DIDow+o 88RARSzcBmK35K1moGNVau/uesR9hBFSB2h6SN37Vo8s9tb0W6i61LUoREfYus1HfX sw3TJLgQsmcrv5nyubP6aql5et1d+ma2GD2LGoqY7iduOuKgndI5ZfXSOkBgIHYmvK GDQ0W4VpVIt4Ud6QQoPpKDCMFlapTjrTbkO33i2fuU5B/eHGXW/16vW8+NRi/Px7K0 wTa/wW0Gz6KkrDXzIrjAEoFyAbAEaXqwVKsrhXKuT6xLturVxkrwe1CTbuyA0eYL9Y NveX++5nacyS67bhq9MOilYs= From: Tomas Volf <~@wolfsden.cz> In-Reply-To: <87r064ippt.fsf@gnu.org> ("Ludovic =?UTF-8?Q?Court=C3=A8s?="'s message of "Wed, 18 Dec 2024 23:35:58 +0100") References: <87r064ippt.fsf@gnu.org> Date: Thu, 19 Dec 2024 01:29:13 +0100 Message-ID: <877c7w7bxi.fsf@wolfsden.cz> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" 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 X-Migadu-Scanner: mx13.migadu.com X-Migadu-Spam-Score: -4.63 X-Spam-Score: -4.63 X-Migadu-Queue-Id: 3B2DE7898C X-TUID: szdpbS/LAMrh --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ludovic Court=C3=A8s writes: > Hello, > > Jake skribis: > >> I think I'm experiencing a bug in Shepherd since version 1.0. >> Whenever I log out and log back in again, my user shepherd from the >> previous login session is still present, and a new user shepherd spawns = for >> the current login session. >> So relogging N times results in N+1 user shepherds. > > I have a user shepherd via Guix Home and I experience the same problem > (though because I rarely log out it=E2=80=99s not really annoying :-)). > > I suspect the problem has to do with how Guix Home determines whether or > not it should launch shepherd, but I haven=E2=80=99t checked yet. When you have another login session active when you log out and in again, new shepherd is *not* spawned. I am guessing here but probably last log out causes XDG_RUNTIME_DIR to be removed (by elogind in my case), so on log in there is no /run/user/$UID/on-first-login-executed, so it runs again and starts the shepherd. But even if that would be solved, since the runtime directory was nuked, there is no shepherd socket around anymore, so the (still running) shepherd from previous login session cannot be contacted by herd. Of the top of my head I can think of two possible solutions: 1. Stop the shepherd on log out. So as we have on-first-login, we would have on-last-logout. I have no idea how to implement that. Maybe we could use ~/.bash_logout? Or some PAM thing? 2. Shepherd could shutdown gracefully when the control socket is deleted from the file system. It is arguable how useful running shepherd is without the socket anyway. Any other ideas? Tomas =2D-=20 There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJCBAEBCgAsFiEEt4NJs4wUfTYpiGikL7/ufbZ/wakFAmdjaNkOHH5Ad29sZnNk ZW4uY3oACgkQL7/ufbZ/wakqSA//X0KE72gpD9M9RRjzrRQjmT/xYRHBPia7ZKIQ 96OH8Rj7qrHLbaQvlfhtEEVbuoIxoxXRHvtLXvdXgxAaD05geIE9qyhid84E6qgM Y+/qiRfsThXjEu2chqLcPxl/xkL6mqk+Jzv2HQyAn0wAp+5N1A4TxCJv14cG+ZOj 0Non6zepnKkeQABDsH0ovzAj79T5LqKDCVryXI6BGpE+kqnH6V+H7nBC8JNGh7eO O4koQuAYcifyAAD4iD/qM0bI3CCtOShBIFalHmJ9Mb4GNVMbTh/Oe2ayVZ0yNB7T NAsLYNeu6UmrGQ7J6cYskPsvnu5qB01PqeGTMvqIVjc8yzb1nEdFHlZ4FLFcZ5mU TT57bpNfB6TMzQ4R3KkffiJ+Oh0EIokDlYukTrvpNqTvnSxWB7GFesej+mgpyQU3 Sc569E+AzO+dDqCO3W7s9otW4qw9MsYyoR2q6yR3qLJWbDAhzp2KQUNoJAG5M+Xy WlpI7QZDUsCNaABwV3J/4DpI+0bnc9EkLcRvVqVyglgsY3QgRTbxiCvtdWFhh5Iq uuzepyV/WHCIW/h58M0lQH8AcF9mFZoLLwMrOV83OGAlI8h6R2ixqhNakWK2QcZP ySUedRh6NaNkxC9FbznYUkuEthpLnmd5PfT32PKhanFq00T+DknnqYm2fOHCQ2X1 VL/AgMk= =fjWz -----END PGP SIGNATURE----- --=-=-=--