c++linuxboostopenmpiboost-mpi

boost::mpi blocking IO not interrupted by linux signals


I use boost::mpi, OpenMPI. boost::mpi::communicator::recv (blocking version) is not interrupted by Linux signals. How can my program can be terminated in the right way with SIGTERM signal?


Solution

  • Problem was resolved: 1. All node except master ignore signals. 2. Master node ignore signals except one thread(this thread calls POSIX pause function). When pause is interrupted, mpi "stop" messages are sent to all nodes. Thus all nodes stop their work.