From unknown Tue Jun 17 01:42:57 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#74940] [PATCH] gnu: openmpi-4: Fix hardcoded call to ssh command. Resent-From: Romain GARBAGE Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 18 Dec 2024 09:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 74940 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74940@debbugs.gnu.org Cc: ludovic.courtes@inria.fr, Romain GARBAGE X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.17345150812590 (code B ref -1); Wed, 18 Dec 2024 09:45:02 +0000 Received: (at submit) by debbugs.gnu.org; 18 Dec 2024 09:44:41 +0000 Received: from localhost ([127.0.0.1]:33438 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tNqbd-0000fd-R5 for submit@debbugs.gnu.org; Wed, 18 Dec 2024 04:44:41 -0500 Received: from lists.gnu.org ([209.51.188.17]:40468) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tNqbY-0000fH-No for submit@debbugs.gnu.org; Wed, 18 Dec 2024 04:44:36 -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 1tNqbX-0003X0-MS for guix-patches@gnu.org; Wed, 18 Dec 2024 04:44:31 -0500 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tNqbU-0004fG-9M for guix-patches@gnu.org; Wed, 18 Dec 2024 04:44:30 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inria.fr; s=dc; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=WDozeRyoJ3baWr66l3ycMyWJjEVsDQMpGkJq9DIs1i8=; b=VJem4ntPPuHYduPeLwRzduuZErJu+WP9gXYx+JtfqPu4gfgOpGhHvzd7 NuUSlTT/Vlxl29Q1/O2bNhvfUIGrgxHRFH6eXr1AYA012vd6mlaIBG8OZ 0PYxvyd1jnel5cxwSxVBsDS6UhkkW/TvcaQ4+Wi/0ope7Vm9ZRUTAxoYO 4=; Authentication-Results: mail3-relais-sop.national.inria.fr; dkim=none (message not signed) header.i=none; spf=SoftFail smtp.mailfrom=romain.garbage@inria.fr; dmarc=fail (p=none dis=none) d=inria.fr X-IronPort-AV: E=Sophos;i="6.12,244,1728943200"; d="scan'208";a="104627099" Received: from 91-160-179-8.subs.proxad.net (HELO localhost.localdomain) ([91.160.179.8]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Dec 2024 10:44:23 +0100 From: Romain GARBAGE Date: Wed, 18 Dec 2024 10:37:39 +0100 Message-ID: <20241218094410.3097-1-romain.garbage@inria.fr> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=192.134.164.104; envelope-from=romain.garbage@inria.fr; helo=mail3-relais-sop.national.inria.fr X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) This patch fixes a runtime error when launching an MPI program using mpiexec/mpirun in an environment where the ssh command is not available. * gnu/packages/mpi.scm (openmpi-4)[inputs]: Add openssh-sans-x. (openmpi-4)[arguments]: Fix path in code. Change-Id: I65255186c37b6eaba3c283c7046163abc2cb38b7 --- The runtime error can be reproduced with: ---8<------------------>8--- $ guix shell -C openmpi@4 hello -- mpirun -np 2 hello -------------------------------------------------------------------------- The value of the MCA parameter "plm_rsh_agent" was set to a path that could not be found: plm_rsh_agent: ssh : rsh Please either unset the parameter, or check that the path is correct -------------------------------------------------------------------------- [guix-A102:00001] [[INVALID],INVALID] FORCE-TERMINATE AT Not found:-13 - error plm_rsh_component.c(335) ---8<------------------>8--- The size of the closure as given by guix size is 406.7 MiB after the patch vs 398.3 MiB before the patch. --- gnu/packages/mpi.scm | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/gnu/packages/mpi.scm b/gnu/packages/mpi.scm index 661531abb9..60a1952809 100644 --- a/gnu/packages/mpi.scm +++ b/gnu/packages/mpi.scm @@ -53,6 +53,7 @@ (define-module (gnu packages mpi) #:use-module (gnu packages parallel) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages ssh) #:use-module (gnu packages valgrind) #:use-module (srfi srfi-1) #:use-module (ice-9 match)) @@ -220,7 +221,8 @@ (define-public openmpi-4 gfortran libfabric libevent - opensm) + opensm + openssh-sans-x) (if-supported psm) (if-supported psm2) (if-supported ucx) @@ -291,6 +293,13 @@ (define-public openmpi-4 '("./ompi/mca/io/romio321/src/io_romio321_component.c") (("MCA_io_romio321_COMPLETE_CONFIGURE_FLAGS") "\"[elided to reduce closure]\"")))) + (add-before 'build 'ssh-absolute-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "./orte/mca/plm/rsh/plm_rsh_component.c" + (("mca_plm_rsh_component.agent = \"ssh : rsh\";") + (format #f "mca_plm_rsh_component.agent = \"~a : rsh\";" + (search-input-file inputs + "bin/ssh")))))) (add-before 'build 'scrub-timestamps ;reproducibility (lambda _ (substitute* '("ompi/tools/ompi_info/param.c" base-commit: cd018214a3c0319451ab46855ea395b2be6a15dc -- 2.46.0 From unknown Tue Jun 17 01:42:57 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Romain GARBAGE Subject: bug#74940: closed (Re: [bug#74940] [PATCH] gnu: openmpi-4: Fix hardcoded call to ssh command.) Message-ID: References: <87zfkm8gfw.fsf@gnu.org> <20241218094410.3097-1-romain.garbage@inria.fr> X-Gnu-PR-Message: they-closed 74940 X-Gnu-PR-Package: guix-patches X-Gnu-PR-Keywords: patch Reply-To: 74940@debbugs.gnu.org Date: Mon, 23 Dec 2024 17:21:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1734974462-32503-1" This is a multi-part message in MIME format... ------------=_1734974462-32503-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #74940: [PATCH] gnu: openmpi-4: Fix hardcoded call to ssh command. which was filed against the guix-patches package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 74940@debbugs.gnu.org. --=20 74940: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D74940 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1734974462-32503-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 74940-done) by debbugs.gnu.org; 23 Dec 2024 17:20:20 +0000 Received: from localhost ([127.0.0.1]:55931 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tPm6N-0008R8-Io for submit@debbugs.gnu.org; Mon, 23 Dec 2024 12:20:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:48014) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tPm6L-0008MT-HG for 74940-done@debbugs.gnu.org; Mon, 23 Dec 2024 12:20:18 -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 1tPm6F-0002I0-Cv; Mon, 23 Dec 2024 12:20:11 -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=+M5kMrFRs0KttZn58ViUKSw+t3+I3xSBDVxB9Q73FLk=; b=gfgvflxr30IoLxlZvJx9 U7EynTyzRARPZGelIck0hvcoQCklSQwOFekA2KGdUNsClw8Z8/KJCoiDfKa57uZJmFyRiSB63S7Ph qLgUk3HoeUZmWEK7n+PFHscd+fxU7e844emWThSgF2dNbsuCaEBJYGkBeZYX5yhBqu451JCE6qoVZ aDmRz5jot7QfnsAQlUZU99sv0NQs4U0/e5Ni+xo/Tqmndq9N9UCNxEurIKOKTjiC79ZOY1i3ikdiE VT9EOgY/SeJ7hdtrH0vhjz1XJofIIlUyUXLI2VrPaGFB26yM+zOT4QdTweKxb9SdZQAh7lelgx6I4 NV9LRmNW5wVeIA==; From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Romain GARBAGE Subject: Re: [bug#74940] [PATCH] gnu: openmpi-4: Fix hardcoded call to ssh command. In-Reply-To: <20241218094410.3097-1-romain.garbage@inria.fr> (Romain GARBAGE's message of "Wed, 18 Dec 2024 10:37:39 +0100") References: <20241218094410.3097-1-romain.garbage@inria.fr> Date: Mon, 23 Dec 2024 18:20:03 +0100 Message-ID: <87zfkm8gfw.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-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 74940-done Cc: 74940-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi there! :-) Romain GARBAGE skribis: > This patch fixes a runtime error when launching an MPI program using > mpiexec/mpirun in an environment where the ssh command is not > available. > > * gnu/packages/mpi.scm (openmpi-4)[inputs]: Add openssh-sans-x. > (openmpi-4)[arguments]: Fix path in code. > > Change-Id: I65255186c37b6eaba3c283c7046163abc2cb38b7 I added a one-line comment in the source to explain, tweaked the commit log, and committed. Thanks for fixing this! Ludo=E2=80=99. ------------=_1734974462-32503-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 18 Dec 2024 09:44:41 +0000 Received: from localhost ([127.0.0.1]:33438 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tNqbd-0000fd-R5 for submit@debbugs.gnu.org; Wed, 18 Dec 2024 04:44:41 -0500 Received: from lists.gnu.org ([209.51.188.17]:40468) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tNqbY-0000fH-No for submit@debbugs.gnu.org; Wed, 18 Dec 2024 04:44:36 -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 1tNqbX-0003X0-MS for guix-patches@gnu.org; Wed, 18 Dec 2024 04:44:31 -0500 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tNqbU-0004fG-9M for guix-patches@gnu.org; Wed, 18 Dec 2024 04:44:30 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inria.fr; s=dc; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=WDozeRyoJ3baWr66l3ycMyWJjEVsDQMpGkJq9DIs1i8=; b=VJem4ntPPuHYduPeLwRzduuZErJu+WP9gXYx+JtfqPu4gfgOpGhHvzd7 NuUSlTT/Vlxl29Q1/O2bNhvfUIGrgxHRFH6eXr1AYA012vd6mlaIBG8OZ 0PYxvyd1jnel5cxwSxVBsDS6UhkkW/TvcaQ4+Wi/0ope7Vm9ZRUTAxoYO 4=; Authentication-Results: mail3-relais-sop.national.inria.fr; dkim=none (message not signed) header.i=none; spf=SoftFail smtp.mailfrom=romain.garbage@inria.fr; dmarc=fail (p=none dis=none) d=inria.fr X-IronPort-AV: E=Sophos;i="6.12,244,1728943200"; d="scan'208";a="104627099" Received: from 91-160-179-8.subs.proxad.net (HELO localhost.localdomain) ([91.160.179.8]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Dec 2024 10:44:23 +0100 From: Romain GARBAGE To: guix-patches@gnu.org Subject: [PATCH] gnu: openmpi-4: Fix hardcoded call to ssh command. Date: Wed, 18 Dec 2024 10:37:39 +0100 Message-ID: <20241218094410.3097-1-romain.garbage@inria.fr> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=192.134.164.104; envelope-from=romain.garbage@inria.fr; helo=mail3-relais-sop.national.inria.fr X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit Cc: ludovic.courtes@inria.fr, Romain GARBAGE X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) This patch fixes a runtime error when launching an MPI program using mpiexec/mpirun in an environment where the ssh command is not available. * gnu/packages/mpi.scm (openmpi-4)[inputs]: Add openssh-sans-x. (openmpi-4)[arguments]: Fix path in code. Change-Id: I65255186c37b6eaba3c283c7046163abc2cb38b7 --- The runtime error can be reproduced with: ---8<------------------>8--- $ guix shell -C openmpi@4 hello -- mpirun -np 2 hello -------------------------------------------------------------------------- The value of the MCA parameter "plm_rsh_agent" was set to a path that could not be found: plm_rsh_agent: ssh : rsh Please either unset the parameter, or check that the path is correct -------------------------------------------------------------------------- [guix-A102:00001] [[INVALID],INVALID] FORCE-TERMINATE AT Not found:-13 - error plm_rsh_component.c(335) ---8<------------------>8--- The size of the closure as given by guix size is 406.7 MiB after the patch vs 398.3 MiB before the patch. --- gnu/packages/mpi.scm | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/gnu/packages/mpi.scm b/gnu/packages/mpi.scm index 661531abb9..60a1952809 100644 --- a/gnu/packages/mpi.scm +++ b/gnu/packages/mpi.scm @@ -53,6 +53,7 @@ (define-module (gnu packages mpi) #:use-module (gnu packages parallel) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages ssh) #:use-module (gnu packages valgrind) #:use-module (srfi srfi-1) #:use-module (ice-9 match)) @@ -220,7 +221,8 @@ (define-public openmpi-4 gfortran libfabric libevent - opensm) + opensm + openssh-sans-x) (if-supported psm) (if-supported psm2) (if-supported ucx) @@ -291,6 +293,13 @@ (define-public openmpi-4 '("./ompi/mca/io/romio321/src/io_romio321_component.c") (("MCA_io_romio321_COMPLETE_CONFIGURE_FLAGS") "\"[elided to reduce closure]\"")))) + (add-before 'build 'ssh-absolute-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "./orte/mca/plm/rsh/plm_rsh_component.c" + (("mca_plm_rsh_component.agent = \"ssh : rsh\";") + (format #f "mca_plm_rsh_component.agent = \"~a : rsh\";" + (search-input-file inputs + "bin/ssh")))))) (add-before 'build 'scrub-timestamps ;reproducibility (lambda _ (substitute* '("ompi/tools/ompi_info/param.c" base-commit: cd018214a3c0319451ab46855ea395b2be6a15dc -- 2.46.0 ------------=_1734974462-32503-1--