From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id KBzAN4HrZmcnfQEAqHPOHw:P1 (envelope-from ) for ; Sat, 21 Dec 2024 16:23:30 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id KBzAN4HrZmcnfQEAqHPOHw (envelope-from ) for ; Sat, 21 Dec 2024 17:23:30 +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=aIaICnm6; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=bvzR7CWA; 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=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734798209; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to: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=gLOjRZxuK+bwiWhhRezOi0k5F6eQPhSVP9o/7zGUeEA=; b=XH92uNq0Z2/UG8U2RCJh4Ng7cufAOCHo/gag19OBrmn0CSzwcJBKoj7wWiZGJQOkwgJHjj Z/vNGNfQz4LfK3P6Jc6Mzy5gpnQ+fjjCEtGcusC/T4CX1FmlLyqbBkEkYauZO2Ax581zpE x9Ux7zZxAllxHTQxENbF27pk6N+d6Us0Z6cllBeF1sfgKv9qT/qZIVI71mYAxv6xFN5xF3 vWAD+80ekDBvRsyr4/YTQ0ayKVZmAXKbvzawdVP+ld1vJesAnmQDvjbHYma0GzAXAmy0ma jn1IvkaQANflN7LTAAC5vS2MjYthdATpVEHF91kqPakyH4r/XIcmlDivh4FRNg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=aIaICnm6; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=bvzR7CWA; 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=pass (policy=none) header.from=gnu.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734798209; a=rsa-sha256; cv=none; b=IMo3GzgFlE0CguAvpsrmoJzCmaXsrizDgxthqGS8h/j/NUUOuYb/I0YMY1KeAmN5vffMty B3QNNKagWHMg3Kr8rKa3YGzENX0QGukU3M7AHWRfHg6FIB1sK9T7pVcVmvTKr/nJeqQWlP CUz2/FFkVuDrSqfs1WkEH6zSPxx9+lVby2F8lmGUaq65xn3lD3xymAoVb5XGqcCJc173EY DlTijJVas+oiNvR46WZvdCbdi0zjdHfWRKfGi49q7fGFkLrKu4QePU+ji06XliM5HShZPe xV4aO5isdMRLbgQUD5lmN58GzlZgM1mWf2Sp3P0Vj4u8Zgg8eb7NiHkJPp34mQ== 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 7757C63600 for ; Sat, 21 Dec 2024 17:23:29 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tP2Fu-0003ak-1D; Sat, 21 Dec 2024 11:23:06 -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 1tP2Fq-0003aR-ST for bug-guix@gnu.org; Sat, 21 Dec 2024 11:23:02 -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 1tP2Fq-0004GM-KT for bug-guix@gnu.org; Sat, 21 Dec 2024 11:23: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=gLOjRZxuK+bwiWhhRezOi0k5F6eQPhSVP9o/7zGUeEA=; b=aIaICnm6p5zvXya0gbpOyq0zX1++YyCZXGhNs2VQQsJHC4KC2IjaO1xbmxcGIXzMAd6vrJuZV1w7tmfJ6eDyFP5I6NXyY8SmSoUFJ0S2mO1zEg7Spr2d+y6fCq2lna/VgT6YdpGn4Rj0H5vP3SM8Nz3qEW3lCxJqUPEArCosrmgFGifAwdpIbL/mOLma5Fginaa5nBFXNhrYnNdEJ8pwK0swEzP2Ey8E91rUTorv5O1JWcFCSQ/YTNt9o0ZYzjE3QEljHHlzPeYCFP90qtAzrQny0lTGvy8570qFqLDgVIWSbdBSK6z2q/jOvMdZYNpc4a2JPH4PfUBU/lbDwdyYzQ==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tP2Fq-0003Nd-C3 for bug-guix@gnu.org; Sat, 21 Dec 2024 11:23:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#31785: Multiple client 'build-paths' RPCs can lead to daemon deadlock Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sat, 21 Dec 2024 16:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31785 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 31785@debbugs.gnu.org Received: via spool by 31785-submit@debbugs.gnu.org id=B31785.173479814912937 (code B ref 31785); Sat, 21 Dec 2024 16:23:02 +0000 Received: (at 31785) by debbugs.gnu.org; 21 Dec 2024 16:22:29 +0000 Received: from localhost ([127.0.0.1]:47418 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tP2FJ-0003Mb-Ai for submit@debbugs.gnu.org; Sat, 21 Dec 2024 11:22:29 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60032) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tP2FH-0003MP-Sh for 31785@debbugs.gnu.org; Sat, 21 Dec 2024 11:22:28 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tP2FC-0004Dh-M0 for 31785@debbugs.gnu.org; Sat, 21 Dec 2024 11:22:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=gLOjRZxuK+bwiWhhRezOi0k5F6eQPhSVP9o/7zGUeEA=; b=bvzR7CWA+/liyVe8zu5Q F8K/ddPVG//swDgTYsIDM/sgVy30XPSi3Ju2h/+cEijnMV89ovUR3J/0PHozFp9mG8og17jP4LGJ0 lShpGzp+jNBC+INPC7TLtAfFMO2/r5MSYDij6iG+iz7HtJRzPvhjlZw9fbMOYB7/eOg3zg/2NaxCI A+VLFj1jVbTkrS08JA+w01eSeBUzy+O3t8qrtuz+xhW08+EJjYKnr5e3ttwNEUERgSKwI3XY0BfDv nRgsgw5dkcnSrNA+P8SHdfm+Q82INBEr3mSSR9OVWf18Gep4uXd1s3lkOJ4JT38QfgKU/eP+825v0 T3ZSTH209vewhQ==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= In-Reply-To: <87602ph0yv.fsf@gnu.org> ("Ludovic =?UTF-8?Q?Court=C3=A8s?="'s message of "Mon, 11 Jun 2018 16:06:16 +0200") References: <87602ph0yv.fsf@gnu.org> Date: Sat, 21 Dec 2024 17:22:15 +0100 Message-ID: <878qs9gg5k.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) 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-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx12.migadu.com X-Migadu-Spam-Score: -1.42 X-Spam-Score: -1.42 X-Migadu-Queue-Id: 7757C63600 X-TUID: eIAI9vHmlaul ludo@gnu.org (Ludovic Court=C3=A8s) skribis: > I tried running this: > > guix build --max-jobs=3D200 $(guix gc -R $(guix build -d inkscape --no-= grafts) | sort) & \ > guix build --max-jobs=3D200 $(guix gc -R $(guix build -d inkscape --no-= grafts) | sort -r) > > =E2=80=A6 also in parallel with this (for good measure): > > guix build --max-jobs=3D200 $(guix gc -R $(guix build -d inkscape --no-= grafts) | sort -R) > > Since we have 3 clients, that leads to 3 guix-daemon processes, and > those are stuck in a deadlock: This strikes again: =E2=80=98cuirass remote-worker=E2=80=99 processes on be= rlin occasionally end up deadlocking in the exact same way. When running =E2=80=98current remote-worker --workers=3D4=E2=80=99, 4 sessi= ons (4 clients) are used, which can lead to that situation, as in this example: --8<---------------cut here---------------start------------->8--- root@hydra-guix-126 ~# guix processes |guix shell recutils -- recsel -p 'Se= ssionPID,ClientCommand,LockHeld' SessionPID: 27250 ClientCommand: /gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/= guile --no-auto-compile -e main -s /gnu/store/ll18sc406b5cqapmvz17v22gh4sry= b24-cuirass-1.2.0-11.e96f088/bin/.cuirass-real remote-worker --user=3Dcuira= ss-worker --workers=3D4 --systems=3Dx86_64-linux,i686-linux --publish-port= =3D5558 --substitute-urls=3Dhttp://141.80.167.131 SessionPID: 27269 ClientCommand: /gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/= guile --no-auto-compile -e main -s /gnu/store/ll18sc406b5cqapmvz17v22gh4sry= b24-cuirass-1.2.0-11.e96f088/bin/.cuirass-real remote-worker --user=3Dcuira= ss-worker --workers=3D4 --systems=3Dx86_64-linux,i686-linux --publish-port= =3D5558 --substitute-urls=3Dhttp://141.80.167.131 LockHeld: /gnu/store/72s7500g3zg2p6fjdc1paazvm1w2xdr2-libva-2.19.0.lock LockHeld: /gnu/store/0bbnhq7bagn6sbj2lmapmdiiw50v3dgz-rav1e-0.7.1.lock SessionPID: 27308 ClientCommand: /gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/= guile --no-auto-compile -e main -s /gnu/store/ll18sc406b5cqapmvz17v22gh4sry= b24-cuirass-1.2.0-11.e96f088/bin/.cuirass-real remote-worker --user=3Dcuira= ss-worker --workers=3D4 --systems=3Dx86_64-linux,i686-linux --publish-port= =3D5558 --substitute-urls=3Dhttp://141.80.167.131 LockHeld: /gnu/store/zf5w9ypk8il0i9y22n81aamypr2qgsmm-dav1d-1.5.0.lock SessionPID: 27345 ClientCommand: /gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/= guile --no-auto-compile -e main -s /gnu/store/ll18sc406b5cqapmvz17v22gh4sry= b24-cuirass-1.2.0-11.e96f088/bin/.cuirass-real remote-worker --user=3Dcuira= ss-worker --workers=3D4 --systems=3Dx86_64-linux,i686-linux --publish-port= =3D5558 --substitute-urls=3Dhttp://141.80.167.131 LockHeld: /gnu/store/0xbi2bgq34yyx2fqjjwpgdv4gkfyaf60-gst-plugins-bad-minim= al-1.22.3.lock LockHeld: /gnu/store/ij5igi5xrp4sx6c78nbvg24lb4ma2f4l-libcbor-0.11.0.lock LockHeld: /gnu/store/czfvm14yy517vb8w2hpp46nyrdrymqyp-libfido2-1.12.0.lock LockHeld: /gnu/store/1ldcq0p20nqy7d3mxdy4yra1ax5ik3xc-mpg123-1.31.2.lock LockHeld: /gnu/store/sadbf1fmb0n9k754x5jbbdklcxbjqlhx-openssh-9.9p1.lock LockHeld: /gnu/store/86rl29llmb7s4sl3bx0vl465mmq7nk6f-gcr-3.41.2.lock SessionPID: 27382 ClientCommand: /gnu/store/mfkz7fvlfpv3ppwbkv0imb19nrf95akf-guile-3.0.9/bin/= guile --no-auto-compile -e main -s /gnu/store/ll18sc406b5cqapmvz17v22gh4sry= b24-cuirass-1.2.0-11.e96f088/bin/.cuirass-real remote-worker --user=3Dcuira= ss-worker --workers=3D4 --systems=3Dx86_64-linux,i686-linux --publish-port= =3D5558 --substitute-urls=3Dhttp://141.80.167.131 --8<---------------cut here---------------end--------------->8--- Here process 27269 holds locks on libva and rav1e and waits forever trying to get the dav1d lock, held by 27308; process 27308 tries to get the rav1e lock; process 27345 tries to get the libva lock. FWIW, each of them is trying to substitute (not build) those things, via the =E2=80=98build-things=E2=80=99 call made after the =E2=80=9Csubstitutin= g ~a inputs for ~a=E2=80=9D message in remote-worker. Ludo=E2=80=99.