<div dir="ltr">Hi Ian and Erik,<div><br></div><div>Setting export OMP_NUM_THREADS=1 did the trick! I&#39;m now up and running.</div><div><br></div><div>Thank you very much for helping me out!</div><div><br></div><div>Gwyneth</div><div><span style="font-size:12.8px"><br></span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Feb 5, 2017 at 9:24 PM, Ian Hinder <span dir="ltr">&lt;<a href="mailto:ian.hinder@aei.mpg.de" target="_blank">ian.hinder@aei.mpg.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div style="word-wrap:break-word">
<br>
<div><span class="">
<div>On 5 Feb 2017, at 18:09, Gwyneth Allwright &lt;<a href="mailto:allgwy001@myuct.ac.za" target="_blank">allgwy001@myuct.ac.za</a>&gt; wrote:</div>
<br class="m_5127393097614429760Apple-interchange-newline">
<blockquote type="cite">
<div dir="ltr">Hi Ian and Erik,
<div><br>
</div>
<div>Thank you very much for all the advice and pointers so far! </div>
<div><br>
</div>
<div>I didn&#39;t compile the ET myself; it was done by an HPC engineer. He is unfamiliar with Cactus and started off not using a config file, so he had to troubleshoot his way through the compilation process. We are both scratching our heads about what the issue
 with mpirun could be.</div>
<div><br>
</div>
<div>I suspect he didn&#39;t set MPI_DIR, so I&#39;m going to suggest that he fixes that and see if recompiling takes care of things.<br>
</div>
<div><br>
</div>
<div>The scheduler automatically terminates jobs that run on too many processors. For my simulation, this appears to happen as soon as TwoPunctures starts generating the initial data. I then get error messages of the form: &quot;Job terminated as it used more cores
 (17.6) than requested (4).&quot; (I switched from requesting 3 processors to requesting 4.) The number of cores it tries to use appears to differ from run to run.<br>
</div>
<br>
The parameter file uses Carpet. It generates the following output (when I request 4 processors):<br>
<br>
INFO (Carpet): MPI is enabled<br>
INFO (Carpet): Carpet is running on 4 processes<br>
INFO (Carpet): This is process 0<br>
INFO (Carpet): OpenMP is enabled<br>
INFO (Carpet): This process contains 16 threads, this is thread 0<br>
INFO (Carpet): There are 64 threads in total<br>
INFO (Carpet): There are 16 threads per process</div>
</blockquote>
<div><br>
</div>
</span><div>It looks like mpirun has started the 4 processes that you asked for, and each of those processes has started 16 threads.  The ET uses OpenMP threads by default.  You need to set the environment variable OMP_NUM_THREADS to the number of threads you want
 per process.  If you just want 4 MPI processes, each with one thread, then you can try putting</div>
<div><br>
</div>
<div>export OMP_NUM_THREADS=1</div>
<div><br>
</div>
<div>before your mpirun command.  On Linux, OMP_NUM_THREADS defaults to the number of &quot;hardware threads&quot; in the system (which will likely be the number of cores multiplied by 2, if hyperthreading is enabled).  So a single process that supports OpenMP will use
 all the cores available.  If you want to have more than one MPI process using OpenMP on the same node, you will have to restrict the number of threads per process.</div>
<div><br>
</div>
<div>Carpet has a couple of environment variables which is uses to cross-check that you have the number of MPI processes and threads that you were expecting.  To help with debugging, you can set</div>
<div><br>
</div>
<div>export CACTUS_NUM_THREADS=1</div>
<div>
<div>export CACTUS_NUM_PROCS=4</div>
<div><br>
</div>
<div>if you want 4 processes with one thread each.  This won&#39;t affect the number of threads or processes, but it will allow Carpet to check that what you intended matches reality.  In this case, it should abort with an error (or in older versions of Carpet,
 output a warning), since while you have 4 processes, each one has 16 threads, not 1.</div>
<div><br>
</div>
</div><span class="">
<blockquote type="cite">
<div dir="ltr">
<div>Mpirun gives me the following information for the node allocation: slots=4, max_slots=0, slots_inuse=0, state=UP.</div>
<div><br>
</div>
<div>The tree view of the processes looks like this:</div>
<div><br>
</div>
<div>PID TTY      STAT   TIME COMMAND<br>
</div>
<div>19503 ?        S      0:00 sshd: allgwy001@pts/7                              <br>
</div>
<div>19504 pts/7    Ss     0:00  \_ -bash</div>
<div> 6047 pts/7    R+     0:00      \_ ps -u allgwy001 f</div>
</div>
</blockquote>
<div><br>
</div>
</span><div>This is not showing the Cactus or mpirun process at all; something is wrong.  Was Cactus running when you typed this?  Were you logged in to the node that it was running on?</div><span class="">
<div><br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>
<div>Adding &quot;cat $PBS_NODEFILE&quot; to my PBS script didn&#39;t seem to produce anything, although I could be doing something stupid. I&#39;m very new to the syntax!<br>
</div>
</div>
</div>
</blockquote>
<div><br>
</div>
</span><div>That&#39;s odd.  </div>
</div><span class="">
<br>
<div>
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div>-- </div>
<div>Ian Hinder</div>
<div><a href="http://members.aei.mpg.de/ianhin" target="_blank">http://members.aei.mpg.de/<wbr>ianhin</a></div>
</div>
</div>
</div>
</div>
</div>
<br>
Disclaimer - University of Cape Town This e-mail is subject to UCT policies and e-mail disclaimer published on our website at <a href="http://www.uct.ac.za/about/policies/emaildisclaimer/" target="_blank">http://www.uct.ac.za/about/<wbr>policies/emaildisclaimer/</a> or obtainable from <a href="tel:+27%2021%20650%209111" value="+27216509111" target="_blank">+27 21 650 9111</a>. If this e-mail is not related to the business
 of UCT, it is sent by the sender in an individual capacity. Please report security incidents or abuse via <a href="mailto:csirt@uct.ac.za" target="_blank">csirt@uct.ac.za</a>
</span></div>

</blockquote></div><br></div>