Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to deploy ODP.NET to IIS 7 on windows server 2008 R2

user507313Aug 23 2016 — edited Aug 28 2016

Hi,

I have installed ODP.NET and VS components for VS 2015 community edition and have a working project that connects to oracle db fine on development machine; is actually an old asmx web service.

When I deploy to IIS 7 on windows server 2008 R2 I run into issues. First off, I am using managed driver and yes its deployed in bin folder. When I have no configuration section noted below I get the following error: System.ArgumentException: Connection string is not well-formed.

Here is my web.config settings for this

<system.data>

    <DbProviderFactories>

      <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client"

           description="Oracle Data Provider for .NET, Managed Driver"

           type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.112.3.50, Culture=neutral, PublicKeyToken=89b483f429c47342" />

    </DbProviderFactories>

    <oracle.manageddataaccess.client>

      <version number="*">

        <dataSources>

          <!-- Customize these connection alias settings to connect to Oracle DB -->

          <dataSource alias="B2KPROD" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=MyHost)(PORT=myport))(CONNECT_DATA=(SERVICE_NAME=mySName))) " />

        </dataSources>

      </version>

    </oracle.manageddataaccess.client>

  </system.data>

I was following some recommendations made at the following concerning deployment http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/12c/r1/appdev/dotnet/Web_version_Fully_Managed_ODPnet_OBE/odpnetmngdrv.html?cid=8127&ssid=0

Other background info/questions:

Oracle client is already installed on the server from before but in a different application pool and I have been using oledb in the past but want to move to ODP. I have configured a new .net 4 application pool that this resource will run under. My understanding was that all that is needed for the managed version is the dll in the bin folder on the deployed server?

Any ideas of whats going wrong?

Regards,

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 25 2016
Added on Aug 23 2016
3 comments
3,872 views