abdelkimo / or-tools

Automatically exported from code.google.com/p/or-tools
1 stars 0 forks source link

Trouble Running Solver Under IIS #19

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I have built a .net project under Visual Studio 12, and with the 32-bit version 
(the development web server with Visual Studio is 32 bit), I am able to run my 
web application in debug mode. However, when I publish it to a web server 
running IIS on Windows Server 2008 (IIS 7.5), on running the web site I get the 
following error:

Could not load file or assembly 'Google.OrTools.LinearSolver.DLL' or one of its 
dependencies. The specified module could not be found

I have tried all permutations of the following:

* 32/64 bit versions of the tool
* project compile to platform target CPU (any, 86, 64 - in both debug and 
release (used for publishing a web application) configurations)
* IIS application pool allow 32-bit applications, and app-pool (and 
application) restarted

Has anyone else managed to get it working in IIS, please?

To reproduce the issue:

* add the DLL as a reference to a .NET project
* in a C# file in the project, add: using Google.OrTools.LinearSolver
* in the same file, add: Solver solver = 
Solver.CreateSolver("IntegerProgramming", "CBC_MIXED_INTEGER_PROGRAMMING");
* publish the application to an IIS web server
* try to open the application in a browser

Original issue reported on code.google.com by GLai...@gmail.com on 23 Jan 2013 at 2:31

GoogleCodeExporter commented 9 years ago
More information: I have got it successfully running under IIS on my own PC, so 
it's just the company web server it won't run on. Will update this issue if I 
find out what the problem is.

Original comment by GLai...@gmail.com on 25 Jan 2013 at 10:53

GoogleCodeExporter commented 9 years ago
I have found the solution: the Microsoft Visual C++ 2010 Redistributable 
Package has to be installed on the web server. I am using the 32-bit version of 
the DLL, so the one I needed was at 
http://www.microsoft.com/en-gb/download/details.aspx?id=5555 . The issue is 
described at http://www.laschinger.net/?p=233 . It would be a good idea to 
mention this issue in the manual - it took time to nail it down.

Original comment by GLai...@gmail.com on 25 Jan 2013 at 3:25

GoogleCodeExporter commented 9 years ago
Hi,
I have the same problem, but I don't have access to install C++ Redistributable 
on server. 
Tried to put msvcr100.dll and msvcp100.dll on bin folder, without sucess. 
Suggestions?
Thanks!

Original comment by dcbri...@gmail.com on 16 Feb 2013 at 1:23

GoogleCodeExporter commented 9 years ago
Hi Daniel - it's probably better to send your question to the mailing list at 
https://groups.google.com/forum/?fromgroups#!forum/or-tools-discuss . FWIW I 
think your issue is political - not technical. You need to either persuade the 
owner of the web server to put the C++ Redistributable package on there, or use 
a different web server.

Original comment by GLai...@gmail.com on 19 Feb 2013 at 4:00

GoogleCodeExporter commented 9 years ago
Solution is to install redistributable on the server.

Original comment by laurent....@gmail.com on 11 Mar 2013 at 2:31

GoogleCodeExporter commented 9 years ago
Just for future reference, dependency now is on msvcr110.dll msvcp110.dll 
download here:
http://www.microsoft.com/en-US/download/details.aspx?id=30679

Used http://www.dependencywalker.com/ to figure it out ...

Original comment by pore...@xpsoft.it on 10 Nov 2014 at 11:14