I had the same problem, and replacing Mumps as the solver was the work-around I used. It works well. Trying to delete the dummy mpi.h file would be an easier fix if it works - I'd try that first, but be ready to replace Mumps in the event removing the dummy header breaks it. <div><br></div><div>- Seth<br><br>On Tuesday, October 20, 2015, Gabriel Hackebeil <<a href="mailto:gabe.hackebeil@gmail.com">gabe.hackebeil@gmail.com</a>> 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">The first thing I would try is rebuilding Ipopt without the ThirdParty/Mumps package. From what I recall, it includes a dummy “mpi.h” file to effectively serialize its own code. It’s very possible that your application is seeing that mpi.h file before the real one.<div><br></div><div>Actually, you might first just try deleting the dummy mpi.h file from the Ipopt include/coin/ThirdParty installation directory, but that may or may not cause a different set of issues.<br><div><br></div><div>Gabe<br><div><br></div><div><div><blockquote type="cite"><div>On Oct 20, 2015, at 2:15 AM, max leo correa cordova <<a href="javascript:_e(%7B%7D,'cvml','max-leo-19@hotmail.com');" target="_blank">max-leo-19@hotmail.com</a>> wrote:</div><br><div><div dir="ltr" style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">Hello! I am new using Ipopt and have tested some example problems with c++ interface. I want to use MPI for solving in parallel multiple NLP, but when runnning with MPI I get an error message. My cpp main file is:<br><br><font size="1" style="font-size:8pt">#include "IpIpoptApplication.hpp"</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">#include "IpSolveStatistics.hpp"</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">#include "MyNLP.hpp"</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">#include "mpi.h"</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">#include <iostream></font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">using namespace Ipopt;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">using namespace std;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">int main(int argc, char** argv)</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">{</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    int size, rank;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    int i; double begin, end;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    ApplicationReturnStatus status;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    MPI_Init(&argc, &argv);<span> </span></font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">     MPI_Comm_size(MPI_COMM_WORLD, &size);<span> </span></font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    MPI_Comm_rank(MPI_COMM_WORLD, &rank);</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    begin = MPI_Wtime();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    if(rank == 0){</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">        SmartPtr<IpoptApplication> app = IpoptApplicationFactory();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">        status = app->Initialize();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">        SmartPtr<TNLP> mynlp = new MyNLP();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">        status = app->OptimizeTNLP(mynlp);</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    }</font><font size="1" style="font-size:8pt"><br>else{<br><br>     }<br></font><font size="1" style="font-size:8pt">    end = MPI_Wtime();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    MPI_Finalize();</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    cout<< end-begin<<endl;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">    return (int) status;</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">}</font><br><br>I compiles fine with:<br><font size="1" style="font-size:8pt">mpic++ -O3 -o example example.cpp -I/home/max/CoinIpopt/build/include/coin -L/home/max/CoinIpopt/build/lib -lipopt -llapack -ldl -lcoinmumps -lblas -lgfortran -lm -lquadmath -lcoinhsl -lcoinmetis</font><font size="1" style="font-size:8pt"><br></font><br>and run with:<br><font size="1" style="font-size:8pt">mpirun -np 3 ./example<br><br><font size="3" style="font-size:12pt">but i get this message error<br><font size="1" style="font-size:8pt">*** The MPI_comm_size() function was called before MPI_INIT was invoked.</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">*** This is disallowed by the MPI standard.</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">*** Your MPI job will now abort.</font><font size="1" style="font-size:8pt"><br></font><font size="1" style="font-size:8pt">[master:4655] Local abort before MPI_INIT completed successfully; not able to aggregate error messages, and not able to guarantee that all other processes were killed!</font><font size="1" style="font-size:8pt"><br></font><br>I am not sure why this error exists. It seems that using the ipopt linkers produce this error. Could you help me please?? Is there something wrong in the compilation step or how can I make ipopt run using MPI?</font></font><span lang="en"><span><font size="3" style="font-size:12pt"><span> </span>I</font>'ll be</span><span> </span><span>grateful for your help.<br>Thanks in advance<span> </span><br>max<br></span></span></div><span style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">_______________________________________________</span><br style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">Ipopt mailing list</span><br style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><a href="javascript:_e(%7B%7D,'cvml','Ipopt@list.coin-or.org');" style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px" target="_blank">Ipopt@list.coin-or.org</a><br style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__list.coin-2Dor.org_mailman_listinfo_ipopt&d=BQMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=nyAMh1egK9edrgq59St5xGhDKYuF8MSeAbmuBm--9_Q&m=fJBHla6FIclN0ECrHUQPUyRuaMPdAEPPDfUoA8Mk28c&s=qqTAWJO9qEJ7XZr1OlEDUORxQNNncnZA26yh5XK8lbw&e=" style="font-family:Calibri;font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px" target="_blank">http://list.coin-or.org/mailman/listinfo/ipopt</a></div></blockquote></div><br></div></div></div></div></blockquote></div>