Re: [OMPI users] MPMD hostfile: executables on same hosts

2020-12-21 Thread Gilles Gouaillardet via users
Vineet,

probably *not* what you expect, but I guess you can try

$ cat host-file
host1 slots=3
host2 slots=3
host3 slots=3

$ mpirun -hostfile host-file -np 2 ./EXE1 : -np 1 ./EXE2 : -np 2
./EXE1 : -np 1 ./EXE2 : -np 2 ./EXE1 : -np 1 ./EXE2


Cheers,

Gilles

On Mon, Dec 21, 2020 at 10:26 PM Vineet Soni via users
 wrote:
>
> Hello,
>
> I'm having touble using the MPMD hostfile in which I want to place 2 
> executables on the same nodes.
>
> For example, I can do this using Intel MPI by:
> $ mpirun -machine host-file -n 6 ./EXE1 : -n 3 ./EXE2
> $ cat host-file
> host1:2
> host2:2
> host3:2
> host1:1
> host2:1
> host3:1
>
> This would place 2 MPI processes of EXE1 and 1 MPI process of EXE2 on host1.
>
> However, I get an error if I define the same hostname twice in the hostfile 
> of OpenMPI:
> $ mpirun -hostfile host-file -np 6 ./EXE1 : -np 3 ./EXE2
> $ cat host-file
> host1 slots=2 max_slots=3
> host2 slots=2 max_slots=3
> host3 slots=2 max_slots=3
> host1 slots=1 max_slots=3
> host2 slots=1 max_slots=3
> host3 slots=1 max_slots=3
>
> Is there a way to place both executables on the same hosts using a hostfile?
>
> Thanks in advance.
>
> Best,
> Vineet


Re: [OMPI users] MPMD hostfile: executables on same hosts

2020-12-21 Thread Ralph Castain via users
You want to use the "sequential" mapper and then specify each proc's location, 
like this for your hostfile:

host1
host1
host2
host2
host3
host3
host1
host2
host3

and then add "--mca rmaps seq" to your mpirun cmd line.

Ralph


On Dec 21, 2020, at 5:22 AM, Vineet Soni via users mailto:users@lists.open-mpi.org> > wrote:

Hello,

I'm having touble using the MPMD hostfile in which I want to place 2 
executables on the same nodes.

For example, I can do this using Intel MPI by:
$ mpirun -machine host-file -n 6 ./EXE1 : -n 3 ./EXE2
$ cat host-file
host1:2
host2:2
host3:2
host1:1
host2:1
host3:1

This would place 2 MPI processes of EXE1 and 1 MPI process of EXE2 on host1.

However, I get an error if I define the same hostname twice in the hostfile of 
OpenMPI:
$ mpirun -hostfile host-file -np 6 ./EXE1 : -np 3 ./EXE2
$ cat host-file
host1 slots=2 max_slots=3
host2 slots=2 max_slots=3
host3 slots=2 max_slots=3
host1 slots=1 max_slots=3
host2 slots=1 max_slots=3
host3 slots=1 max_slots=3

Is there a way to place both executables on the same hosts using a hostfile?

Thanks in advance.

Best,
Vineet



[OMPI users] MPMD hostfile: executables on same hosts

2020-12-21 Thread Vineet Soni via users
Hello, 

I'm having touble using the MPMD hostfile in which I want to place 2 
executables on the same nodes. 

For example, I can do this using Intel MPI by: 
$ mpirun -machine host-file -n 6 ./EXE1 : -n 3 ./EXE2 
$ cat host-file 
host1:2 
host2:2 
host3:2 
host1:1 
host2:1 
host3:1 

This would place 2 MPI processes of EXE1 and 1 MPI process of EXE2 on host1. 

However, I get an error if I define the same hostname twice in the hostfile of 
OpenMPI: 
$ mpirun -hostfile host-file -np 6 ./EXE1 : -np 3 ./EXE2 
$ cat host-file 
host1 slots=2 max_slots=3 
host2 slots=2 max_slots=3 
host3 slots=2 max_slots=3 
host1 slots=1 max_slots=3 
host2 slots=1 max_slots=3 
host3 slots=1 max_slots=3 

Is there a way to place both executables on the same hosts using a hostfile? 

Thanks in advance. 

Best, 
Vineet