title: How can I use start-stop-daemon to start a mpi task?
body: <p>I use <code>demo.sh</code> to start a daemon mpi task:</p>
  
  <pre><code>#! /bin/sh
  if ! kill -0 $(cat pid) &gt; /dev/null 2&gt;&amp;1
  then
    /sbin/start-stop-daemon -p pid -m pid --start --background --exec mpirun -n 2 a.out
  fi
  </code></pre>
  
  <p>But it can not work, how can I use <code>start-stop-daemon</code> to start a mpi job?</p>