Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.

 View Only
Expand all | Collapse all

Java CPLEX Error - dll won't load, says my platform is IA-32 but it is 64

  • 1.  Java CPLEX Error - dll won't load, says my platform is IA-32 but it is 64

    Posted Thu September 29, 2011 12:24 PM

    Originally posted by: LuisdelaTorre


    I'm setting up a fresh install of CPLEX 12.3 through academic initiative on a new computer. It's running Windows 7 Pro 64-bit (I checked this through my computer, it is 64-bit!). I'm using Eclipse 3.7 and when I run code I get the message

    java.lang.UnsatisfiedLinkError: C:\Program Files\IBM\ILOG\CPLEX_Studio_Academic123\cplex\bin\x64_win64\cplex123.dll: Can't load AMD 64-bit .dll on a IA 32-bit platform
    java.library.path must point to the directory containing the CPLEX shared library
    try invoking java with java -Djava.library.path=...

    I've added -Djava.library.path="C:\Program Files\IBM\ILOG\CPLEX_Studio_Academic123\cplex\bin\x64_win64" to my VM arguments.

    As far as I can tell: Windows is 64-bit. Eclipse is 64-bit. Java is 64-bit. CPLEX is 64-bit.

    Why am I getting this message? Will my Eclipse configuration help? I'm attaching it.
    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: Java CPLEX Error - dll won't load, says my platform is IA-32 but it is 64

    Posted Thu September 29, 2011 04:38 PM

    Originally posted by: SystemAdmin


    Hello,

    > As far as I can tell: Windows is 64-bit. Eclipse is 64-bit. Java is
    > 64-bit. CPLEX is 64-bit.

    The error seems to point towards an inappropriate JRE version on your machine. Can you open a command prompt window and then execute "java -version" to check on it? It seems that the eclipse is using 32 bit JRE when it needs a 64 bit target.

    To make sure that the eclipse uses the 64 bit Java, you could add the "-vm <path_to_64_bit_JDK>" in the eclipse.ini file and then try.

    Other than this, do make sure that you follow other instructions (like including the appropriate cplex.jar and .dll files) per the following documentation link:

    http://publib.boulder.ibm.com/infocenter/cosinfoc/v12r3/index.jsp?topic=%2Filog.odms.cplex.help%2FContent%2FOptimization%2FDocumentation%2FOptimization_Studio%2F_pubskel%2Fps_gscplex1296.html

    I hope this helps.
    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: Java CPLEX Error - dll won't load, says my platform is IA-32 but it is 64

    Posted Thu September 29, 2011 05:45 PM

    Originally posted by: LuisdelaTorre


    Thanks! I noticed that I had both 32 and 64-bit JRE and JDK installed. Uninstalling the 32-bit version did it.
    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: Java CPLEX Error - dll won't load, says my platform is IA-32 but it is 64

    Posted Thu September 29, 2011 05:46 PM

    Originally posted by: LuisdelaTorre


    See my last post for how I fixed the problem.
    #CPLEXOptimizers
    #DecisionOptimization