boost::mpi accross several computers

Hello, from the tutorial ( http://www.osl.iu.edu/~dgregor/boost.mpi/libs/parallel/doc/html/) I read this sentence : "A Boost.MPI program consists of many cooperating processes (possibly running on different computers) that communicate among themselves by passing messages." How would that be done ? Can't find anything in the doc about doing it... an example would be great :) Thank you in advance Philippe

Hi, On Thu, 8 Feb 2007 15:18:31 +0100 "Philippe Vaucher" <philippe.vaucher@gmail.com> wrote:
How would that be done ? Can't find anything in the doc about doing it... an example would be great :)
Boost.MPI is basically a nice C++ wrapper around MPI. Before you can use Boost.MPI, you have to install a MPI implementation [1,2]. A basic knowledge of the MPI standard [3] is very useful. So, you might want to read the book by Peter Pacheco or the book, that is advertised in my signature. ;-) These books are about MPI and C, they do not cover Boost.MPI! Heiko [1] http://www.open-mpi.org/ [2] http://www.mcs.anl.gov/mpi/mpich2 [3] http://www.mpi-forum.org/ -- -- Programming in Basic causes brain damage. -- (Edsger Wybe Dijkstra) -- Cluster Computing @ http://www.clustercomputing.de -- Heiko Bauke @ http://www.physics.ox.ac.uk/users/bauke

Boost.MPI is basically a nice C++ wrapper around MPI. Before you can use Boost.MPI, you have to install a MPI implementation [1,2]. A basic knowledge of the MPI standard [3] is very useful.
Well, thank you for the links and stuffs but it doesn't quite tell me wether the sentence telling MPI could work across several computers is supported by boost::mpi. Let me explain a bit what I'm trying to do: I discover other computers at runtime (through zeroconf), then I need to connect to them and communicate with them. I was going to use boost::asio and maintain a connected tcp socket with each of the other pcs (I'm coding an application on each computers). Then I saw this sentence from boost::mpi talking about it can work across several computers, and I wondered wether it could be possible to use it instead of rolling my own protocol for communication between the computers. For example, mpi would be of no use if there's no runtime-way to talk to a process on another computer... which is what the api *looks* like as I don't see any connect() or monitor_machine() or whatever api which would allow me to get the processes from another computer. Thank you. Philippe

Philippe Vaucher wrote:
Then I saw this sentence from boost::mpi talking about it can work across several computers, and I wondered wether it could be possible to use it instead of rolling my own protocol for communication between the computers. For example, mpi would be of no use if there's no runtime-way to talk to a process on another computer... which is what the api *looks* like as I don't see any connect() or monitor_machine() or whatever api which would allow me to get the processes from another computer.
Thank you. Philippe
MPI based solutions are probably not the tool for what you want to do. Whether using boost.mpi or the underlying MPI libraries, your description of your problem does not sound like what MPI is designed to do. What MPI does is allow one computer to run processes on a cluster of computers. It starts those processes and facilitates communication between the processes. The typical usage is to have the same code running on each computer in the cluster, though it is also possible to runn different code on different boxes. These processes all run to completion during the MPI session. If I understand what you want to do, this is not a good match. I think you want to connect with and communicate with already running processes on other computers. Probably you also want to be able to end your session without ending the processes on the remote machines. This is not the usage MPI is built to do, so I don't think MPI (with boost.mpi, or by itself) is the tool for you. John Phillips
participants (3)
-
Heiko Bauke
-
John Phillips
-
Philippe Vaucher