This discussion is archived
0 Replies Latest reply: Sep 17, 2012 8:42 AM by siromega RSS

Problems with deploying ODAC to web server

siromega Newbie
Currently Being Moderated
I have a ASP.NET 4.0 MVC application using Entity Framework and ODAC r4 11.2.0.3.0. I have Oracle 10g client installed on the server (2003) already. I installed the 32-bit ODAC 4 XCopy deployment to the server using the batch file. So I have two Oracle installs on the computer.

c:\oracle\ora10g\
c:\oracle\odac11g32\

The odac11g32 isn't in the PATH environment variable, and because I have a bunch of web apps using the 10g driver now I don't want to disturb them (if I add the bin directory to the PATH env variable, it breaks my existing apps for some reason).

So I read that I can use the DllPath variable in the web.config file..

+<add name="DllPath" value="C:\Oracle\odac11g32\bin"/>+

I added it along with all the other variables I've seen in the examples, but I still am getting an error when I try to run the application...

Unable to load DLL 'OraOps11w.dll': The specified procedure could not be found. (Exception from HRESULT: 0x8007007F)

I used Process Explorer to make sure it was loading the correct DLL from the GAC and there is no oracle.dataaccess.dll in the BIN directory of my application. I used Dependency Walker to make sure that all the supporting DLLs work for the DLL mentioned in the error message (I got an error with shlwapi.dll but the DW docs say thats not an issue because its delay-load or something like that).



[DllNotFoundException: Unable to load DLL 'OraOps11w.dll': The specified procedure could not be found. (Exception from HRESULT: 0x8007007F)]
Oracle.DataAccess.Client.OpsTrace.Trace(UInt32 level, String[] args) +0
Oracle.DataAccess.Client.OraTrace.Trace(UInt32 TraceLevel, String[] args) +58
Oracle.DataAccess.Client.OpoErrResManager.GetErrorMesg(Int32 errorcode, String[] args) +328
Oracle.DataAccess.Client.OracleError..ctor(Int32 errNumber, String dataSrc, String procedure, String errMsg) +82
Oracle.DataAccess.Client.OracleException..ctor(Int32 errCode, String dataSrc, String procedure, String errMsg) +127
Oracle.DataAccess.Client.OracleException..ctor(Int32 errCode) +49
Oracle.DataAccess.Client.OracleInit.Initialize() +465
Oracle.DataAccess.Client.OracleClientFactory..cctor() +76

[TypeInitializationException: The type initializer for 'Oracle.DataAccess.Client.OracleClientFactory' threw an exception.]

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points