I _think_ what the user is saying is that their "hello world" program is 
returning rank=0 for all procs when started with mpirun, but not when started 
with MPICH's mpiexec.hydra.

The most likely problem is that your "hello" program wasn't built against OMPI 
- are you trying to run the same binary with both mpirun and mpiexec.hydra? If 
so, that won't work.


On Nov 14, 2019, at 8:58 AM, Jeff Squyres (jsquyres) via users 
<users@lists.open-mpi.org <mailto:users@lists.open-mpi.org> > wrote:

Are you asking a question about MPICH?  If so, I think you should probably ask 
on their mailing lists -- they're an entirely different project from Open MPI.

Also, I think you mean "processes", not "threads".

On Nov 11, 2019, at 5:01 PM, sdcycling via users <users@lists.open-mpi.org 
<mailto:users@lists.open-mpi.org> > wrote:


mpirun -n 4 myprog is only giving me 1 thread when I would like 4.  How do I 
specify 4 threads? mpiexec.hydra -n 4 correctly gives me 4 threads. I have 
tried to configure a hostfile with no luck.  I am running Ubuntu 18.04.  Here 
is a listing of hello.f90:

        use mpi
        implicit none
        integer, parameter :: i4= selected_real_kind(4)
        integer (i4) :: mype
        integer (i4) :: nprocs
        integer (i4) :: ierr
        call mpi_init(ierr)
        call mpi_comm_size(mpi_comm_world,nprocs,ierr)
        call mpi_comm_rank(mpi_comm_world,mype,ierr)
        write(6,*) 'Hello World',mype
        call mpi_finalize(ierr)
        stop
        end

Here is a mpirun example:

        mpirun -n 4 a.out
        Hello World           0
        Hello World           0
        Hello World           0
        Hello World           0

Here is a mpiexec.hydra example:

        mpiexec.hydra -n 4 a.out
        Hello World           3
        Hello World           1
        Hello World           2
        Hello World           0

Here is the output of lscpu:

        Architecture:        x86_64
        CPU op-mode(s):      32-bit, 64-bit
        Byte Order:          Little Endian
        CPU(s):              256
        On-line CPU(s) list: 0-255
        Thread(s) per core:  2
        Core(s) per socket:  64
        Socket(s):           2
        NUMA node(s):        2
        Vendor ID:           AuthenticAMD
        CPU family:          23
        Model:               49
        Model name:          AMD EPYC 7742 64-Core Processor
        Stepping:            0
        CPU MHz:             1499.900
        CPU max MHz:         2250.0000
        CPU min MHz:         1500.0000
        BogoMIPS:            4499.95
        Virtualization:      AMD-V
        L1d cache:           32K
        L1i cache:           32K
        L2 cache:            512K
        L3 cache:            16384K
        NUMA node0 CPU(s):   0-63,128-191
        NUMA node1 CPU(s):   64-127,192-255












-- 
Jeff Squyres
jsquy...@cisco.com <mailto:jsquy...@cisco.com> 


Reply via email to