Forum Stats

  • 3,781,019 Users
  • 2,254,467 Discussions
  • 7,879,529 Comments

Discussions

ORA-01017 with Managed Provider 4.112.3.60. Bug with ODP on Win 2008 R2?

1022962
1022962 Member Posts: 3
edited Aug 9, 2013 10:09AM in ODP.NET

I'm experiencing some trouble with the manage provider and I can't seem to figure out what's causing the issue.

At first, the Managed Provider seemed to be a drop in replacement for the Unmanaged Provider.  However, when we moved some code to our testing environments, the application started failing with a 'Logon Denied' error.

Our dev machines are 64 bit Win 7 and our test machines are Win 2008 R2.  The DEV machines do not have any trouble connecting to the database with the identical connection string used in the test environment.  I can connect to the database using sql plus with the connection string used in the application.

I'm at a loss on how to trouble shoot this.

Thanks.

Jon

Tagged:
user1714674Nelson Rothermeluser2284427

Best Answer

  • 1031481
    1031481 Member Posts: 1
    Accepted Answer

    I think I know what's going on here. It looks like the AES algorithm is being used to encrypt the password while connecting to the database. The AES implementation in .NET is NOT FIPS compliant which causes problems in the public sector (I noticed you were in the government, as am I). The only way I was able to get around this issue was to turn off FIPS Policy enforcement (http://msdn.microsoft.com/en-us/library/hh202806.aspx.) The joys of security...

    Nelson Rothermeluser2284427
«134

Answers

  • 1022962
    1022962 Member Posts: 3

    Some more information: so this definitely seems like a WIN 2008 R2 bug.  I just had a new WIN7 VM provisioned.  I had our dba create a brand new user.  I moved a web app to the newly provisioned machine - when I ran the app I got an error loading the DTC assembly.  This is normal because you also have to make sure the VC++ Runtime has been installed.  I installed it, restarted the app, and the application CAN connect to Oracle.  Same code, same config on 2008 R2 fails with ORA-01017.

    So any thoughts on what's the problem with Win Server 2008 R2?

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,009 Employee

    This may be an already known issue. Can you provide the following details:

    1) What is the oracle error # and error message?

    2) What is the version of:

        a) Oracle Database

        b) ODP.NET unmanaged

    3) What is the connection string being used? (please exclude JUST the password from your connection string)

  • 1022962
    1022962 Member Posts: 3

    1) What is the oracle error # and error message?


    ORA-01017 "Logon Denied"

    2) What is the version of:

        a) Oracle Database

    11.2.0.1

       

       b) ODP.NET unmanaged

    the unmanaged we're using the 11.2.0.3.  But the logon denied error happens specifically with the managed provider and only on Windows Server 2008.

    3) What is the connection string being used? (please exclude JUST the password from your connection string)

    Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=scan2.xxx.xxx.gov)(PORT=1531))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=dev2.xxx.xxx.gov))));User ID=SOME_USER_1; Password=something;

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,009 Employee

    We tried to reproduce this problem in house with Windows 2008 R2, but were unable to. Can you email me a simple reproducible test case with .NET config files and *.ora files included? If you can also include a trace at Tracel Level 7 that would be helpful in diagnosis.

    My email is alex.keh (at) oracle.com.

  • Lannie Liberty
    Lannie Liberty Member Posts: 224 Blue Ribbon

    I am having the same problem.

    Unmanaged driver ... app connects on 64-bit Windows 7, Windows 2003, WIndows 2008 R2 all connecting to remote DB server (Redhat Linux Oracle 11gR2)

    Managed driver with tnsnames.ora in app folder... app connects on 64-bit Windows 7 and Windows 2003, but not Windows 2008 R2.

    All three app servers running 64-bit OS, fully patched 32-bit and 64-bit C++ runtimes for 2005, 2008, 2010, and client is from the ODP.NET unmanaged Client Install for Oracle Client 11g203.

    App compiled as 64-bit.  Tried 32-bit compile, same situation.

    The only difference I see between Oracle Client Setups on the three boxes is the addition of one line in SQLNET.ora on Windows 2008.

    It uses the NAMES.DEFAULT_DOMAIN clause to allow dropping .WORLD from instance naming.

    But, this is working fine with the unmanaged driver.

    Tried placing sqlnet.ora in the application folder and still connection fails.

    have not yet explicitly put tnsnames path statement in the app.config (though have not had to with Windows 7 and Windows 2003)

    I will generate some error logs tomorrow for you.

  • Lannie Liberty
    Lannie Liberty Member Posts: 224 Blue Ribbon

    Unable to get the TRACE options working in APP.CONIFG (In Win 7.. perhaps you can share a working APP.CONFIG file for .NET 4.0),

    but I do have exception message on Windows 2008

    7/10/2013 7:30:26 AM -- Number: 3135
    ErrorCode: -2147467259
    DataSource: Oracle.ManagedDataAccess
    Source: Oracle Data Provider for .NET, Managed Driver
    Procedure:
    Message: ORA-03135: Connection lost contact
    TargetSite: Void HandleError(OracleInternal.Common.OracleTraceLevel, OracleInternal.Common.OracleTraceTag, System.Exception)
    StackTrace:    at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.TTC.TTCProtocolNegotiation.ReadResponse()
       at OracleInternal.ServiceObjects.OracleConnectionImpl.DoProtocolNegotiation()
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at ReadOracle.GetUserTableList(String strOwner) in ReadOracle.vb:line 41

    Full ex message:

    Oracle.ManagedDataAccess.Client.OracleException (0x80004005):

    ORA-03135: Connection lost contact ---> OracleInternal.Network.NetworkException (0x80004005): ORA-03135: Connection lost contact ---> System.Net.Sockets.SocketException (0x80004005): An existing connection was forcibly closed by the remote host
       at OracleInternal.Network.ReaderStream.Read(OraBuf OB)
       at OracleInternal.Network.ReaderStream.Read(OraBuf OB)
       at OracleInternal.TTC.OraBufReader.GetDataFromNetwork()
       at OracleInternal.TTC.OraBufReader.Read(Boolean bIgnoreData)
       at OracleInternal.TTC.MarshallingEngine.UnmarshalUB1(Boolean bIgnoreData)
       at OracleInternal.TTC.TTCProtocolNegotiation.ReadResponse()
       at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.TTC.TTCProtocolNegotiation.ReadResponse()
       at OracleInternal.ServiceObjects.OracleConnectionImpl.DoProtocolNegotiation()
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at ReadOracle.GetUserTableList(String strOwner) in ReadOracle.vb:line 41

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,009 Employee

    Here's a sample app.config that enables all the levels (which we want) that generates the trace to "c:\temp":

    <?xml version="1.0" encoding="utf-8" ?>

    <configuration>

       <oracle.manageddataaccess.client>

         <version number="*">

           <settings>

             <setting name="TraceOption" value="7"/>

             <setting name="TraceFileLocation" value="C:\temp"/>

           </settings>

         </version>

       </oracle.manageddataaccess.client> 

    </configuration>

    Also, you will need an entry in the machine.config by running

    OraProvCfg.exe /action:config /product:odpm /frameworkversion:v4.0.30319 /providerpath:C:\<some location>\Oracle.ManagedDataAccess.dll

    ...if such an entry does not yet exist.   Once it's configured properly, it will look like the following:

    <configuration>

         <configSections>

                 <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=....  />

                 ....

         </configSections>

         ...

    <configuration>

    That should generate a trace.

  • Lannie Liberty
    Lannie Liberty Member Posts: 224 Blue Ribbon

    Thanks

    Will get this running on Windows 7 then move to the WIndows 2008, and send TRACE files.

    Might take a day or two.

  • Lannie Liberty
    Lannie Liberty Member Posts: 224 Blue Ribbon

    Trace now working.

    App halts at oracle connection.open()

    SQLNET.ora and TNSNAMES.ora are present in application directory along with managed driver version .60

    TNS_ADMIN set to the application directory

    app works on Windows 7 and Windows 2003, but abruptly halts on oracle conn.open in Windows 2008

    ping host IP pass

    tnsping instance name (SID) pass

    same app using unmanaged driver works with release 4 ODP.NET 11g203 client on same Windows 2008 app server and remote database server

    do not have Oracle_SID in the OS ENV since multiple database servers exist in the environment.

    2013-07-18 09:41:11.390932 TID:1   (CFG) (ENV)      Machine Name : BOX07

    2013-07-18 09:41:11.406557 TID:1   (CFG) (ENV)      User Name : me

    2013-07-18 09:41:11.422182 TID:1   (CFG) (ENV)      OS Version : Microsoft Windows NT 6.1.7601 Service Pack 1

    2013-07-18 09:41:11.422182 TID:1   (CFG) (ENV)      64-bit OS : True

    2013-07-18 09:41:11.422182 TID:1   (CFG) (ENV)      64-bit Process : True

    2013-07-18 09:41:11.422182 TID:1   (CFG) (ENV)      .NET Runtime Version : 4.0.30319.1008

    2013-07-18 09:41:11.437808 TID:1   (CFG) (VER)      Oracle Data Provider for .NET, Managed Driver Version : 4.112.3.60

    2013-07-18 09:41:11.437808 TID:1   (CFG) (.NET)     TraceOption : 1

    2013-07-18 09:41:11.437808 TID:1   (CFG) (.NET)     TraceFileLocation : I:\apptest

    2013-07-18 09:41:11.437808 TID:1   (CFG) (.NET)     TNS_ADMIN : I:\apptest

    2013-07-18 09:41:11.453433 TID:1   (CFG) (.NET)     TraceLevel : 7

    2013-07-18 09:41:11.484683 TID:1   (CFG) (SQLNET)   SQLNET.AUTHENTICATION_SERVICES : (NTS)

    2013-07-18 09:41:11.484683 TID:1   (CFG) (SQLNET)   NAMES.DEFAULT_DOMAIN : (WORLD)

    2013-07-18 09:41:11.500309 TID:1   (CFG) (SQLNET)   mydb.world : (DESCRIPTION =(ADDRESS = (PROTOCOL = TCP)(Host = 10.10.10.20)(Port = 1512))(CONNECT_DATA = (SERVICE_NAME = mydb)))

    2013-07-18 09:41:11.547185 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.ctor()

    2013-07-18 09:41:11.547185 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.ctor()

    2013-07-18 09:41:11.562810 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.578435 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.578435 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.578435 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.594061 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.594061 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.594061 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.594061 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.609686 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.609686 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.609686 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.609686 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.625311 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.625311 TID:1   (PUB) (ENT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.625311 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.ContainsKey()

    2013-07-18 09:41:11.625311 TID:1   (PUB) (EXT) OracleConnectionStringBuilder.TryGetValue()

    2013-07-18 09:41:11.656562 TID:1   (PUB) (ENT) OracleConnection.ctor()

    2013-07-18 09:41:11.672187 TID:1   (PRI) (CP) (ENT) ConnectionString.GetCS()

    2013-07-18 09:41:11.687812 TID:1   (PRI) (CP) (ENT) ConnectionString.ctor()

    2013-07-18 09:41:11.703438 TID:1   (PRI) (CP) (ENT) ConnectionString.Parse()

    2013-07-18 09:41:11.719063 TID:1   (PRI) (CP) (ENT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.719063 TID:1   (PRI) (CP) (EXT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.719063 TID:1   (PRI) (CP) (ENT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.734688 TID:1   (PRI) (CP) (EXT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.734688 TID:1   (PRI) (CP) (ENT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.734688 TID:1   (PRI) (CP) (EXT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.734688 TID:1   (PRI) (CP) (ENT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.750314 TID:1   (PRI) (CP) (EXT) ConnectionString.SetProperty()

    2013-07-18 09:41:11.750314 TID:1   (PRI) (CP) (EXT) ConnectionString.Parse()

    2013-07-18 09:41:11.750314 TID:1   (PRI) (CP) (EXT) ConnectionString.ctor()

    2013-07-18 09:41:11.750314 TID:1   (PRI) (CP) (EXT) ConnectionString.GetCS()

    2013-07-18 09:41:11.765939 TID:1   (PUB) (EXT) OracleConnection.ctor()

    2013-07-18 09:41:11.765939 TID:1   (PUB) (ENT) OracleCommand.ctor()

    2013-07-18 09:41:11.781564 TID:1   (PUB) (EXT) OracleCommand.ctor()

    2013-07-18 09:41:11.781564 TID:1   (PRI) (ENT) OracleParameterCollection.ctor()

    2013-07-18 09:41:11.781564 TID:1   (PRI) (EXT) OracleParameterCollection.ctor()

    2013-07-18 09:41:11.781564 TID:1   (PUB) (ENT) OracleParameterCollection.Clear()

    2013-07-18 09:41:11.781564 TID:1   (PUB) (EXT) OracleParameterCollection.Clear()

    2013-07-18 09:41:11.797189 TID:1   (PUB) (ENT) OracleParameterCollection.Add()

    2013-07-18 09:41:11.797189 TID:1   (PRI) (SVC) (ENT) OracleParameter.ctor()

    2013-07-18 09:41:11.797189 TID:1   (PRI) (SVC) (EXT) OracleParameter.ctor()

    2013-07-18 09:41:11.797189 TID:1   (PUB) (ENT) OracleParameter.ctor()

    2013-07-18 09:41:11.812815 TID:1   (PUB) (EXT) OracleParameter.ctor()

    2013-07-18 09:41:11.812815 TID:1   (PUB) (ENT) OracleParameterCollection.Add()

    2013-07-18 09:41:11.812815 TID:1   (PUB) (EXT) OracleParameterCollection.Add()

    2013-07-18 09:41:11.812815 TID:1   (PUB) (EXT) OracleParameterCollection.Add()

    2013-07-18 09:41:11.828440 TID:1   (PUB) (ENT) OracleConnection.Open() (conid=52252659) (state=Closed) (sessid=0) (implid=0) (oper=open)

    2013-07-18 09:41:11.844065 TID:1   (PRI) (CP) (ENT) OracleConnectionDispenser`3..cctor()

    2013-07-18 09:41:11.844065 TID:1   (PRI) (CP) (EXT) OracleConnectionDispenser`3..cctor()

    2013-07-18 09:41:11.844065 TID:1   (PRI) (CP) (ENT) OracleConnectionDispenser`3.Get()

    2013-07-18 09:41:11.859691 TID:1   (PRI) (CP) (ENT) PoolManager`3.ctor()

    2013-07-18 09:41:11.859691 TID:1   (PRI) (CP) (EXT) PoolManager`3.ctor()

    2013-07-18 09:41:11.875316 TID:1   (PRI) (CP) (ENT) PoolManager`3.Initialize() (pmid=41462866) (txnctxid=41462866)  (constr=PERSIST SECURITY INFO=True;USER ID=MYSCHEMA;DATA SOURCE=MYDB;)

    2013-07-18 09:41:11.875316 TID:1   (PRI) (CP) (ENT) ConnectionString.Secure()

    2013-07-18 09:41:11.875316 TID:1   (PRI) (CP) (EXT) ConnectionString.Secure()

    2013-07-18 09:41:11.875316 TID:1   (PRI) (CP) (EXT) PoolManager`3.Initialize() (pmid=41462866)

    2013-07-18 09:41:11.875316 TID:1   (PRI) (BUF) (OBP.CTOR) (poolid:37621475) (OracleConnectionDispenser`3.GetPM)

    2013-07-18 09:41:11.890941 TID:1   (PRI) (TUN) Tuning thread started.

    2013-07-18 09:41:11.890941 TID:1   (PRI) (TUN) OracleTuningAgent::Register(): Registered pool PERSIST SECURITY INFO=True;USER ID=MYSCHEMA;DATA SOURCE=MYDB.WORLD;PASSWORD={notes: not sure if this is supposed to be empty in trc file}

    2013-07-18 09:41:11.906567 TID:1   (PRI) (ENT) OracleConnectionDispenser`3.Get()

    2013-07-18 09:41:11.922192 TID:1   (PUB) (CP) (ERR) OracleConnectionDispenser`3.Get() System.TypeInitializationException: The type initializer for 'System.Transactions.Diagnostics.DiagnosticTrace' threw an exception. --->

       System.Configuration.ConfigurationErrorsException: An error occurred creating the configuration section handler for system.diagnostics: Attempt by method 'System.Configuration.TypeUtil.CreateInstanceRestricted(System.Type, System.Type)'

         to access method 'System.Diagnostics.TraceSection..ctor()' failed. (I:\apptest\CATAJACK.exe.Config line 35) --->

       System.MethodAccessException: Attempt by method 'System.Configuration.TypeUtil.CreateInstanceRestricted(System.Type, System.Type)' to access method 'System.Diagnostics.TraceSection..ctor()' failed. --->

       System.Security.SecurityException: Request failed.

       at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(RuntimeAssembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandleInternal rmh, SecurityAction action, Object demand, IPermission permThatFailed)

       at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandleInternal rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)

       at System.Security.PermissionListSet.CheckSetDemandWithModification(PermissionSet pset, PermissionSet& alteredDemandSet, RuntimeMethodHandleInternal rmh)

       at System.Security.PermissionListSet.CheckSetDemand(PermissionSet pset, RuntimeMethodHandleInternal rmh)

       at System.Security.PermissionListSet.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)

       at System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant)

       --- End of inner exception stack trace ---

       at System.RuntimeMethodHandle.PerformSecurityCheck(Object obj, RuntimeMethodHandleInternal method, RuntimeType parent, UInt32 invocationFlags)

       at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean fillCache)

       at System.Activator.CreateInstance(Type type, Boolean nonPublic)

       at System.Configuration.TypeUtil.CreateInstanceRestricted(Type callingType, Type targetType)

       at System.Configuration.ConfigurationElement.CreateElement(Type type)

       at System.Configuration.ConfigurationElement.get_Item(ConfigurationProperty prop)

       at System.Configuration.ConfigurationElement.Reset(ConfigurationElement parentElement)

       at System.Configuration.RuntimeConfigurationRecord.RuntimeConfigurationFactory.CreateSectionImpl(RuntimeConfigurationRecord configRecord, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.RuntimeConfigurationRecord.RuntimeConfigurationFactory.CreateSectionWithRestrictedPermissions(RuntimeConfigurationRecord configRecord, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.RuntimeConfigurationRecord.CreateSection(Boolean inputIsTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.BaseConfigurationRecord.CallCreateSection(Boolean inputIsTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader, String filename, Int32 line)

       --- End of inner exception stack trace ---

       at System.Configuration.BaseConfigurationRecord.EvaluateOne(String[] keys, SectionInput input, Boolean isTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentResult)

       at System.Configuration.BaseConfigurationRecord.Evaluate(FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentResult, Boolean getLkg, Boolean getRuntimeObject, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSection(String configKey)

       at System.Configuration.ConfigurationManager.GetSection(String sectionName)

       at System.Configuration.PrivilegedConfigurationManager.GetSection(String sectionName)

       at System.Diagnostics.DiagnosticsConfiguration.Initialize()

       at System.Diagnostics.DiagnosticsConfiguration.get_Sources()

       at System.Diagnostics.TraceSource.Initialize()

       at System.Transactions.Diagnostics.DiagnosticTrace..cctor()

       --- End of inner exception stack trace ---

       at System.Transactions.Transaction.get_Current()

       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)

    2013-07-18 09:41:11.937817 TID:1   (PRI) (EXT) OracleConnectionDispenser`3.Get()

    2013-07-18 09:41:11.937817 TID:1   (PRI) (CP) (EXT) OracleConnectionDispenser`3.Get()

    2013-07-18 09:41:11.937817 TID:1   (PRI) (ENT) OracleConnection.Open()

    2013-07-18 09:41:11.937817 TID:1   (PUB) (ERR) OracleConnection.Open() System.TypeInitializationException: The type initializer for 'System.Transactions.Diagnostics.DiagnosticTrace' threw an exception. --->

       System.Configuration.ConfigurationErrorsException: An error occurred creating the configuration section handler for system.diagnostics: Attempt by method 'System.Configuration.TypeUtil.CreateInstanceRestricted(System.Type, System.Type)'

         to access method 'System.Diagnostics.TraceSection..ctor()' failed. (I:\apptest\CATAJACK.exe.Config line 35) --->

       System.MethodAccessException: Attempt by method 'System.Configuration.TypeUtil.CreateInstanceRestricted(System.Type, System.Type)' to access method 'System.Diagnostics.TraceSection..ctor()' failed. --->

       System.Security.SecurityException: Request failed.

       at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(RuntimeAssembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandleInternal rmh, SecurityAction action, Object demand, IPermission permThatFailed)

       at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandleInternal rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)

       at System.Security.PermissionListSet.CheckSetDemandWithModification(PermissionSet pset, PermissionSet& alteredDemandSet, RuntimeMethodHandleInternal rmh)

       at System.Security.PermissionListSet.CheckSetDemand(PermissionSet pset, RuntimeMethodHandleInternal rmh)

       at System.Security.PermissionListSet.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)

       at System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant)

       --- End of inner exception stack trace ---

       at System.RuntimeMethodHandle.PerformSecurityCheck(Object obj, RuntimeMethodHandleInternal method, RuntimeType parent, UInt32 invocationFlags)

       at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean fillCache)

       at System.Activator.CreateInstance(Type type, Boolean nonPublic)

       at System.Configuration.TypeUtil.CreateInstanceRestricted(Type callingType, Type targetType)

       at System.Configuration.ConfigurationElement.CreateElement(Type type)

       at System.Configuration.ConfigurationElement.get_Item(ConfigurationProperty prop)

       at System.Configuration.ConfigurationElement.Reset(ConfigurationElement parentElement)

       at System.Configuration.RuntimeConfigurationRecord.RuntimeConfigurationFactory.CreateSectionImpl(RuntimeConfigurationRecord configRecord, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.RuntimeConfigurationRecord.RuntimeConfigurationFactory.CreateSectionWithRestrictedPermissions(RuntimeConfigurationRecord configRecord, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.RuntimeConfigurationRecord.CreateSection(Boolean inputIsTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader)

       at System.Configuration.BaseConfigurationRecord.CallCreateSection(Boolean inputIsTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentConfig, ConfigXmlReader reader, String filename, Int32 line)

       --- End of inner exception stack trace ---

       at System.Configuration.BaseConfigurationRecord.EvaluateOne(String[] keys, SectionInput input, Boolean isTrusted, FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentResult)

       at System.Configuration.BaseConfigurationRecord.Evaluate(FactoryRecord factoryRecord, SectionRecord sectionRecord, Object parentResult, Boolean getLkg, Boolean getRuntimeObject, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)

       at System.Configuration.BaseConfigurationRecord.GetSection(String configKey)

       at System.Configuration.ConfigurationManager.GetSection(String sectionName)

       at System.Configuration.PrivilegedConfigurationManager.GetSection(String sectionName)

       at System.Diagnostics.DiagnosticsConfiguration.Initialize()

       at System.Diagnostics.DiagnosticsConfiguration.get_Sources()

       at System.Diagnostics.TraceSource.Initialize()

       at System.Transactions.Diagnostics.DiagnosticTrace..cctor()

       --- End of inner exception stack trace ---

       at System.Transactions.Transaction.get_Current()

       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)

       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()

    2013-07-18 09:41:11.953442 TID:1   (PRI) (EXT) OracleConnection.Open()

    +++++++++++++++++++++++++++++++

    exception info

    7/18/2013 9:46:53 AM -- Number: 12545
    ErrorCode: -2147467259
    DataSource: Oracle.ManagedDataAccess
    Source: Oracle Data Provider for .NET, Managed Driver
    Procedure:
    Message: ORA-12545: Network Transport: Unable to resolve connect hostname
    TargetSite: Void HandleError(OracleInternal.Common.OracleTraceLevel, OracleInternal.Common.OracleTraceTag, System.Exception)
    StackTrace:    at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at CATAJACK.ReadOracle.GetUserTableList(String strOwner)

    Full ex message: Oracle.ManagedDataAccess.Client.OracleException (0x80004005): ORA-12545: Network Transport: Unable to resolve connect hostname ---> OracleInternal.Network.NetworkException (0x80004005): ORA-12545: Network Transport: Unable to resolve connect hostname ---> System.Net.Sockets.SocketException (0x80004005): No such host is known
       at System.Net.Dns.InternalGetHostByName(String hostName, Boolean includeIPv6)
       at System.Net.Dns.GetHostAddresses(String hostNameOrAddress)
       at OracleInternal.Network.TcpTransportAdapter.Connect(ConnectionOption conOption)
       at OracleInternal.Network.OracleCommunication.DoConnect(String tnsDescriptor)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at CATAJACK.ReadOracle.GetUserTableList(String strOwner)

    ++++++++++++++++

    7/18/2013 9:48:01 AM -- Number: 12545
    ErrorCode: -2147467259
    DataSource: Oracle.ManagedDataAccess
    Source: Oracle Data Provider for .NET, Managed Driver
    Procedure:
    Message: ORA-12545: Network Transport: Unable to resolve connect hostname
    TargetSite: Void HandleError(OracleInternal.Common.OracleTraceLevel, OracleInternal.Common.OracleTraceTag, System.Exception)
    StackTrace:    at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at CATAJACK.ReadOracle.GetUserTableList(String strOwner)

    Full ex message: Oracle.ManagedDataAccess.Client.OracleException (0x80004005): ORA-12545: Network Transport: Unable to resolve connect hostname ---> OracleInternal.Network.NetworkException (0x80004005): ORA-12545: Network Transport: Unable to resolve connect hostname ---> System.Net.Sockets.SocketException (0x80004005): No such host is known
       at System.Net.Dns.InternalGetHostByName(String hostName, Boolean includeIPv6)
       at System.Net.Dns.GetHostAddresses(String hostNameOrAddress)
       at OracleInternal.Network.TcpTransportAdapter.Connect(ConnectionOption conOption)
       at OracleInternal.Network.OracleCommunication.DoConnect(String tnsDescriptor)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at Oracle.ManagedDataAccess.Client.OracleException.HandleError(OracleTraceLevel level, OracleTraceTag tag, Exception ex)
       at OracleInternal.ServiceObjects.OracleConnectionImpl.Connect(ConnectionString cs, Boolean bOpenEndUserSession)
       at OracleInternal.ConnectionPool.PoolManager`3.CreateNewPR(Int32 reqCount, Boolean bForPoolPopulation, ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.PoolManager`3.Get(ConnectionString csWithDiffOrNewPwd)
       at OracleInternal.ConnectionPool.OraclePoolManager.Get(ConnectionString csWithNewPassword)
       at OracleInternal.ConnectionPool.OracleConnectionDispenser`3.Get(ConnectionString cs, PM conPM, ConnectionString pmCS, SecureString securedPassword, SecureString securedProxyPassword)
       at Oracle.ManagedDataAccess.Client.OracleConnection.Open()
       at CATAJACK.ReadOracle.GetUserTableList(String strOwner)

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,009 Employee

    Form the trace, it appears that you have a config error in

    I:\apptest\CATAJACK.exe.Config line 35

    If the data sources were defined in the app/web/machine.config then it's possible that NONE of those entries were actually read and thus a TNS descriptor issue as we won't know how to resolve it.

    Can you resolve the configuration file issue first to see if that resolves the problem?

    As for the following line of:

    2013-07-18 09:41:11.890941 TID:1   (PRI) (TUN) OracleTuningAgent::Register(): Registered pool PERSIST SECURITY INFO=True;USER ID=MYSCHEMA;DATA SOURCE=MYDB.WORLD;PASSWORD={notes: not sure if this is supposed to be empty in trc file}

    Yes, the password is supposed to be empty in the trace.

This discussion has been closed.