Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Do you know how I could get this MPI_init ?
Thanks
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 | | Room# D114A ===========================================================================
On 2021-09-19 11:33 a.m., Patrick Dupre wrote:
Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Do you know how I could get this MPI_init ?
Did you install "mpich-devel"?
Actually MPI_Init is in openmpi-devel but I add to make the path PATH=/usr/lib64/openmpi/bin:$PATH for mpicc which is bizare.
Furthermore, I tried man mpicc
/usr/share/man/mpich-x86_64/man1/mpicc.1.gz /usr/share/man/openmpi-x86_64/man1/mpicc.1.gz
But it does not work
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 | | Room# D114A ===========================================================================
Sent: Sunday, September 19, 2021 at 10:28 PM From: "Samuel Sieb" samuel@sieb.net To: users@lists.fedoraproject.org Subject: Re: mpi_Init
On 2021-09-19 11:33 a.m., Patrick Dupre wrote:
Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Do you know how I could get this MPI_init ?
Did you install "mpich-devel"? _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
On Sun, Sep 19, 2021 at 10:42:43PM +0200, Patrick Dupre wrote:
Actually MPI_Init is in openmpi-devel but I add to make the path PATH=/usr/lib64/openmpi/bin:$PATH for mpicc which is bizare.
Furthermore, I tried man mpicc
/usr/share/man/mpich-x86_64/man1/mpicc.1.gz /usr/share/man/openmpi-x86_64/man1/mpicc.1.gz
But it does not work
You don't wnat to use the OpenMPI headers to compile something with mpich. As has been said, install the mpich-devel package, which has its own headers in /usr/include/mpich-x86_64/ that defined MPI_Init, and don't forget to load the environment module first!
On Sun, Sep 19, 2021 at 08:33:21PM +0200, Patrick Dupre wrote:
Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Rather than setting the PATH, you should have run:
module load mpi/mpich-x86_64
... before compiling. That loads the mpich environment module, which defines a bunch of environment modules. Environment Modules are very popular on HPC systems, lets you have multiple versions and varieties of packages without them stepping on each other. You load the appropriate module before compiling or running software and it gets the specific libraries/executables/includes/etc.
For example, here is the module file for mpich:
$ cat /usr/share/modulefiles/mpi/mpich-x86_64 #%Module 1.0 # # MPICH module for use with 'environment-modules' package: #
# Only allow one mpi module to be loaded at a time conflict mpi
# Define prefix so PATH and MANPATH can be updated. setenv MPI_BIN /usr/lib64/mpich/bin setenv MPI_SYSCONFIG /etc/mpich-x86_64 setenv MPI_FORTRAN_MOD_DIR /usr/lib64/gfortran/modules/mpich setenv MPI_INCLUDE /usr/include/mpich-x86_64 setenv MPI_LIB /usr/lib64/mpich/lib setenv MPI_MAN /usr/share/man/mpich-x86_64 setenv MPI_PYTHON_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON2_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON3_SITEARCH /usr/lib64/python3.9/site-packages/mpich setenv MPI_COMPILER mpich-x86_64 setenv MPI_SUFFIX _mpich setenv MPI_HOME /usr/lib64/mpich prepend-path PATH /usr/lib64/mpich/bin prepend-path LD_LIBRARY_PATH /usr/lib64/mpich/lib prepend-path MANPATH :/usr/share/man/mpich-x86_64 prepend-path PKG_CONFIG_PATH /usr/lib64/mpich/lib/pkgconfig
On Sun, Sep 19, 2021 at 04:35:14PM -0400, Jonathan Billings wrote:
... before compiling. That loads the mpich environment module, which defines a bunch of environment modules.
Er... I mean it defines a bunch of environment *variables*.
setenv MPI_PYTHON_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON2_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON3_SITEARCH /usr/lib64/python3.9/site-packages/mpich
Oops. Looks like the package references Python 2 but those RPM macros are gone. I suppose that's a bug.
OK
Very good.
But I get
from process 0 out of 1 on Teucidide
with MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
How can I set numprocs to 2 for example?
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 | | Room# D114A ===========================================================================
Sent: Sunday, September 19, 2021 at 10:35 PM From: "Jonathan Billings" billings@negate.org To: users@lists.fedoraproject.org Subject: Re: mpi_Init
On Sun, Sep 19, 2021 at 08:33:21PM +0200, Patrick Dupre wrote:
Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Rather than setting the PATH, you should have run:
module load mpi/mpich-x86_64
... before compiling. That loads the mpich environment module, which defines a bunch of environment modules. Environment Modules are very popular on HPC systems, lets you have multiple versions and varieties of packages without them stepping on each other. You load the appropriate module before compiling or running software and it gets the specific libraries/executables/includes/etc.
For example, here is the module file for mpich:
$ cat /usr/share/modulefiles/mpi/mpich-x86_64 #%Module 1.0 # # MPICH module for use with 'environment-modules' package: #
# Only allow one mpi module to be loaded at a time conflict mpi
# Define prefix so PATH and MANPATH can be updated. setenv MPI_BIN /usr/lib64/mpich/bin setenv MPI_SYSCONFIG /etc/mpich-x86_64 setenv MPI_FORTRAN_MOD_DIR /usr/lib64/gfortran/modules/mpich setenv MPI_INCLUDE /usr/include/mpich-x86_64 setenv MPI_LIB /usr/lib64/mpich/lib setenv MPI_MAN /usr/share/man/mpich-x86_64 setenv MPI_PYTHON_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON2_SITEARCH %{python2_sitearch}/mpich setenv MPI_PYTHON3_SITEARCH /usr/lib64/python3.9/site-packages/mpich setenv MPI_COMPILER mpich-x86_64 setenv MPI_SUFFIX _mpich setenv MPI_HOME /usr/lib64/mpich prepend-path PATH /usr/lib64/mpich/bin prepend-path LD_LIBRARY_PATH /usr/lib64/mpich/lib prepend-path MANPATH :/usr/share/man/mpich-x86_64 prepend-path PKG_CONFIG_PATH /usr/lib64/mpich/lib/pkgconfig
-- Jonathan Billings billings@negate.org _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
On Sun, Sep 19, 2021 at 10:53:10PM +0200, Patrick Dupre wrote:
OK
Very good.
But I get
from process 0 out of 1 on Teucidide
with MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
How can I set numprocs to 2 for example?
That's between you and your compiler. I think MPI support might be out of scope for the Fedora mailing list. :)
On Sun, 19 Sept 2021 at 15:33, Patrick Dupre pdupre@gmx.com wrote:
Hello,
I installed mpich and set the path to /usr/lib64/mpich/bin however, it seems that I need MPI_init
Checking if MPI is available checking for mpif90... mpif90 checking for MPI_Init... no checking for MPI_Init in -lmpi... no checking for MPI_Init in -lmpich... no configure: error: MPI not found: openmpi
Try "module load mipch-x86_64".
Fedora uses environment modules to switch between MIP libraries and tools https://docs.fedoraproject.org/en-US/neurofedora/mpi/:
% ls /usr/share/modulefiles/mpi mpich-x86_64 openmpi-x86_64
I prefer Lmod (lua modules with tcl support) over the original tcl environment modules.
Do you know how I could get this MPI_init ?
Thanks
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 | | Room# D114A =========================================================================== _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure