Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] Unable to schedule an MPI tasks
From: Özgür Pekçağlıyan (ozgur.pekcagliyan_at_[hidden])
Date: 2014-01-03 18:44:19


Hello,

It is against the idea of parallel computing but you can do something like
this

if (rank == 0)
{
    //do something
    int done = 1;
    MPI_Send((void*)&done, 1, MPI_INT, 1, 0, MPI_COMM_WORLD):
}
else if (rank == 1)
{
    MPI_Status * status;
    int start;
    MPI_Recv((void*)&start, 1, MPI_INT, 0, 0, MPI_COMM_WORLD,
status)://will wait till receive something from rank=0
    //do something
}

Simply, just keep second program on waiting. This is the simplest solution
I can come up with :)

On Fri, Jan 3, 2014 at 6:36 PM, Ng Shi Wei <nsw_1216_at_[hidden]> wrote:

> Hi Reuti,
>
> May I know how to starts the second mpi program once the previous program
> is finished? I am using Fedora Cluster.
>
> Hope you can provide me some guide on this.
>
> Thank you.
>
> Best Regards,
> Shi Wei.
>
> > From: reuti_at_[hidden]
> > Date: Tue, 27 Aug 2013 08:56:26 +0200
> > To: users_at_[hidden]
> > Subject: Re: [OMPI users] Unable to schedule an MPI tasks
> >
> > Hi,
> >
> > Am 27.08.2013 um 03:45 schrieb Ng Shi Wei:
> >
> > > Due to the time constraints, I would like to run the mpi program by
> scheduling the program to run on desired time using the "at" command.
> However, it seems that the mpirun doesn't execute the mpi program at the
> desired time using the "at" command.
> > >
> > > I would like to ask is there any other method to schedule a program to
> run ?
> > > For best, it can straight away starts the second mpi program once the
> previous program is finished.
> >
> > Is this a local machine just for you, a cluster for you or one shared by
> several users?
> >
> > You could also think of implementing a full blown queuingsystem like
> SoGE https://arc.liv.ac.uk/trac/SGE or Torque
> http://www.adaptivecomputing.com/products/open-source/torque/
> >
> > You don't have to think about a time when the job should start then
> (even though this is possible with the -a option), but requesting the
> intended number of cores will allow a job to run as soon as these resources
> are available. I.e. you can submit several jobs at once but they will be
> executed one after the other without oversubscribing the available
> resources.
> >
> > -- Reuti
> >
> > NB: There is also the command `batch` in the at-suite to start the next
> job when the load drops under a certain value.
> >
> >
> > > Hope to get some reply from you all.
> > >
> > > Thanks in advance.
> > >
> > > Best Regards,
> > > Shi Wei
> > > _______________________________________________
> > > users mailing list
> > > users_at_[hidden]
> > > http://www.open-mpi.org/mailman/listinfo.cgi/users
> >
> > _______________________________________________
> > users mailing list
> > users_at_[hidden]
> > http://www.open-mpi.org/mailman/listinfo.cgi/users
>
> _______________________________________________
> users mailing list
> users_at_[hidden]
> http://www.open-mpi.org/mailman/listinfo.cgi/users
>

-- 
Özgür Pekçağlıyan
B.Sc. in Computer Engineering
M.Sc. in Computer Engineering