Ipopt installation in Linux - problems

560 views
Skip to first unread message

Mauricio Moreno Zambrano

unread,
Mar 16, 2017, 9:08:49 AM3/16/17
to Pyomo Forum
Hi everyone. Again

I have been trying to install ipopt in Ubuntu 14.04.5 (GNU/Linux 3.13.0-65-generic x86_64).

After had followed the instruction of the Coin project, I am getting the next error message

WARNING: "[base]/dist-packages/pyomo/opt/base/solvers.py", 201, __solver_call__
        Failed to create solver with name 'ipopt':
        Failed to set executable for solver asl. File with name=/opt/CoinIpopt/build/lib/pkgconfig either does not exist or it is not executable. To skip this validation, call set_executable with validate=False.
Traceback (most recent call last):
  File "camu_v0.8_vanilla.py", line 158, in <module>
    results = solver.solve(instance,tee=True,file_determinism=1)
  File "/usr/local/lib/python2.7/dist-packages/pyomo/opt/base/solvers.py", line 126, in solve
    self._solver_error('solve')
  File "/usr/local/lib/python2.7/dist-packages/pyomo/opt/base/solvers.py", line 154, in _solver_error
    + "\n\toptions: %s" % ( self.options, ) )
RuntimeError: Attempting to use an unavailable solver.

The SolverFactory was unable to create the solver "ipopt"
and returned an UnknownSolver object.  This error is raised at the point
where the UnknownSolver object was used as if it were valid (by calling
method "solve").

The original solver was created with the following parameters:
        executable: /opt/CoinIpopt/build/lib/pkgconfig
        type: ipopt
        _args: ()
        options: {}

I have tried by specifying directly the path where my 'ipopt.pc' executable is located, as Gabe suggested in an older post and I had also added this location into my path in the .bashrc file. Both options hadn't worked.

I hope that someone else that had passed by something similar could give advice,

Thanks in advance

Mauricio 

Gabriel Hackebeil

unread,
Mar 16, 2017, 10:00:41 AM3/16/17
to pyomo...@googlegroups.com
Mauricio,

I’ve never encountered a case where this error wasn’t due to a problem with the PATH setup. If you are on linux and your PATH is set up correctly, then you should be able to type ‘ipopt’ inside the terminal from any directory and see output like:

$ ipopt
No stub!
usage: ipopt [options] stub [-AMPL] [<assignment> ...]

Options:
--  {end of options}
-=  {show name= possibilities}
-?  {show usage}
-bf {read boundsfile f}
-e  {suppress echoing of assignments}
-of {write .sol file to file f}
-s  {write .sol file (without -AMPL)}
-v  {just show version}

Can you verify that this works?

Also, note that it is not the location of “ipopt.pc” that you need to add to your path, but rather, the location of “ipopt” (which is usually inside of a directory named “bin”).

Gabe

--
You received this message because you are subscribed to the Google Groups "Pyomo Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyomo-forum...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages