Suggestions on parallel computing
Up to now only rudimentary support for parallel computing was installed to the cluster, because concrete projects didn't exist. The following tips should serve beginners. Please speak for your personal demands directly with the Informatik-RZ.
PBS / Torque
The simpleTorque scheduler works very basic and permits only one inefektive use to cluster in a productive system. Examples of commands to PBS::
qmgr -c 'p s' | show server configuration |
pbsnodes -a | verify that all nodes answer |
qstat -a | show all jobs |
qstat -B | summary status |
qsub | submit a job |
For extensions or another scheduler please contact the Informatik-RZ.
OpenMPI
You find further documentation to OpenMPI on the Internet. Simple example:
Source code mpitest.c :
#include <mpi.h>
#include <stdio.h>
#include <unistd.h>
int main(int argc, char **argv)
{
int rank;
char hostname[256];
MPI_Init(&argc,&argv);
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
gethostname(hostname,255);
printf("Hello world! I am process number: %d on host %s\n", rank, hostname);
MPI_Finalize();
return 0;
}
Compile with the command:
> mpicc -o mpitest.out mpitest.c
Run on the cluster:
> mpirun -np 6 -H ccblade1,ccblade2,ccblade3 mpitest.out
Result:
Hello world! I am process number: 0 on host ccblade1
Hello world! I am process number: 1 on host ccblade1
Hello world! I am process number: 2 on host ccblade2
Hello world! I am process number: 3 on host ccblade2
Hello world! I am process number: 4 on host ccblade3
Hello world! I am process number: 5 on host ccblade3
The Informatik-RZ offers no instruction to parallel computing. Please contact if needed functions must be installed.
Access without password
Several applications distribute the processes in SSH to several machines. It is necessary for it that you can login without password. The keys can be generated as follows (example):
> cd ~/.ssh
> ssh-keygen -t rsa
> cp id_rsa.pub authorized_keys
> chmod 700 ~/.ssh
> chmod 600 authorized_keys
You find further information with search items like "SSH ssh-keygen authorized_keys" on the Internet.