Pardiso linear solver with Ipopt


#1

I have installed Pardiso 5.0 and I have gotten it to work with Pardiso.jl by following the instructions in the README. When I try getting Ipopt.jl to work with PARDISO by following the steps in this issue, I run into problems

I put my libpardiso.so into julia/lib, ran Pkg.build("Ipopt") and then tried solving a model with Model(solver=IpoptSolver(linear_solver="pardiso")). Upon doing so, I get the following error:

Exception of type: OPTION_INVALID in file "IpAlgBuilder.cpp" at line 416:
 Exception message: Selected linear solver Pardiso not available.
Tried to obtain Pardiso from shared library "libpardiso.so", but the following error occured:
/home/devja964/julia/bin/../lib/libpardiso.so: undefined symbol: _gfortran_concat_string

EXIT: Invalid option encountered.
WARNING: Ipopt finished with status Invalid_Option
WARNING: Not solved to optimality, status: Error
  3.952053 seconds (3.86 M allocations: 205.034 MiB, 1.98% gc time)
:Error

Some extra information that may be useful…

julia> versioninfo()
Julia Version 0.6.0
Commit 9036443 (2017-06-19 13:05 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.9.1 (ORCJIT, haswell)

julia> Pkg.status("Ipopt")
 - Ipopt                         0.2.6

Update:
I managed to get things working on my laptop running OSX, so this seems to be a linux issue. If anyone has experience getting ipopt/pardiso playing together on linux, then I would love to hear of any tricks that you might have up your sleeve.


#2

What happens if you do Libdl.dlopen("libgfortran", Libdl.RTLD_GLOBAL)?


#3

On my OSX machine (where things are working) I get:

julia> Libdl.dlopen("libgfortran", Libdl.RTLD_GLOBAL)
Ptr{Void} @0x00007feb6cd572c0

But I can’t test the linux machine until tomorrow morning (which is in about 12 hours from now in New Zealand), sorry.

I do have a seperate issue on my OSX machine related to Pardiso.jl. I noticed that the README says that support for macOS is experimental. I managed to get things working, but I had to change the location of some gfortran libraries. I assumed that the problem was not your fault and I wanted to do a little bit more research before I told you about it.

Basically, to get things working I had to move all of the files in the folder /usr/local/gfortran/lib to /usr/local/lib. Before I moved all of the files, I got the following error:

julia> Pkg.build("Pardiso")
INFO: Building Pardiso
found library but it failed to load due to:
could not load library "/Users/jackdevine/.julia/v0.6/Pardiso/deps/libpardiso500-MACOS-X86-64.dylib"
dlopen(/Users/jackdevine/.julia/v0.6/Pardiso/deps/libpardiso500-MACOS-X86-64.dylib, 9): Library not loaded: /usr/local/lib/libgomp.1.dylib
  Referenced from: /Users/jackdevine/.julia/v0.6/Pardiso/deps/libpardiso500-MACOS-X86-64.dylib
  Reason: image not foundfound library but it failed to load due to:
could not load library "libpardiso500-MACOS-X86-64.dylib"
dlopen(libpardiso500-MACOS-X86-64.dylib, 9): Library not loaded: /usr/local/lib/libgomp.1.dylib
  Referenced from: /Users/jackdevine/.julia/v0.6/Pardiso/deps/libpardiso500-MACOS-X86-64.dylib
  Reason: image not founddid not find libpardiso, assuming PARDISO 5.0 is not installed
found MKLROOT key, using it

#4

On my linux machine (where things are not working), I get:

julia> Libdl.dlopen("libgfortran", Libdl.RTLD_GLOBAL)
Ptr{Void} @0x000000000348dbd0