cylondata / twister2

A composable framework for fast and scalable data analytics
https://twister2.org
Apache License 2.0
57 stars 32 forks source link

executing standalone mpi from java and mpi workers with a script #922

Closed ahmet-uyar closed 4 years ago

ahmet-uyar commented 4 years ago

Hi Supun,

I executed mpirun directly from java and used mpiworker.sh script to start workers. You can use the debugging feature now. I also sent command line parameters from mpimaster to workers as environment variables. So, mpiworker.sh script is much more readable. If you can test the debugging first, that would be great.

Ahmet

supunkamburugamuve commented 4 years ago

@ahmet-uyar I was trying to understand how the two scripts are connected. I can see they both invoke java. I thought one script is going to use the other in the mpi command

ahmet-uyar commented 4 years ago

@supunkamburugamuve, both standalone and slurm use a single script. In standalone, the script is used as the prelaunch script when starting workers. In Slurm, the script is used in the submitting client to invoke sbatch command to submit the mpi job.

supunkamburugamuve commented 4 years ago

I could find one mpi launcher script. Is there a one in standalone directory?

ahmet-uyar commented 4 years ago

@supunkamburugamuve There is mpiworker.sh script in standalone directory.

supunkamburugamuve commented 4 years ago

I see you have included the mpi command launch in the Java program. How can we specify custom MPI command arguments?

ahmet-uyar commented 4 years ago

[I see you have included the mpi command launch in the Java program. How can we specify custom MPI command arguments?]

@supunkamburugamuve, we can either add a configuration parameter for that or have two separate scripts. One for the mpimaster and the other is for the mpiworker.

supunkamburugamuve commented 4 years ago

I'm fine with both options.

supunkamburugamuve commented 4 years ago

@chathurawidanage wdyt about these options?

chathurawidanage commented 4 years ago

+1 for adding a config parameter. Are we going to add that to YAML files or accept from the twister2 submit command itself?

ahmet-uyar commented 4 years ago

@chathurawidanage I think YAML file would be better.