ORA-02049

HI,
I get the "ORA-02049: timeout: distributed transaction waiting for lock" error message when i run the query
it works fine when i run it in pl/sql developer but in apex.... no bueno
what does this error mean and how can i fix it???
select a.object_name, b.cogipf_username, trunc(c.cogipf_localtimestamp), count(trunc(c.cogipf_localtimestamp)) logon_count
from cognos_security_groups a, prod_coglog.cogipf_userlogon@cognosp b, prod_coglog.cogipf_runreport@cognosp c
where b.cogipf_sessionid = c.cogipf_sessionid
and a.object_name = :P1_Object_Name
and c.cogipf_localtimestamp <= sysdate
and c.cogipf_localtimestamp >= add_months(sysdate, -1)
group by a.object_name, b.cogipf_username, trunc(c.cogipf_localtimestamp)\
i think it has something to do with my database links
Edited by: Daniel Garcia on Dec 16, 2008 11:55 AM

Daniel,
I experienced the same earlier today. I deleted the region and then reconstructed it. The page then operated normally.
Jeff

Similar Messages

  • ORA-02049: timeout: distributed transaction waiting for lock

    Hi,
    My name is Guneet and I'm working on an application running on BEA Weblogic Server 9.2 running on a Red Hat Linux box using Oracle 10g as the database. My problem is that recently our code started getting the following exception while updating a database table.
    java.sql.SQLException: [BEA][Oracle JDBC Driver][Oracle]ORA-02049: timeout: distributed transaction waiting for lock
    Application Details
    * Using Stateless Session EJB
    * Only one Business method in this EJB with transaction attribute set to "required"
    * This method executes two select queries & one update query
    * We are using JDBC to access the database.
    * We have configured a Data Source & are using it to get a database connection.
    * Weblogic's Oracle Driver is being used.
    More details
    * The application has been running well since a month.
    * Two days ago,the update query failed with the above error.
    * At that time, a single client was accessing the system.
    * Once this problem occurs, it starts appearing frequently.
    * Eventually a request to get a connection from the Data Source times out & the exception copied at the end is thrown
    * At this stage the application gets stuck and all requests trying to get a connection end up with this exception.
    * Fortunately, Restarting the Weblogic Server gets us out of this problem and transactions resume normally.
    Now my questions are
    # Why is this error happening & what does it mean?
    # It looks like the second exception (unable to get a connection from ds) is an after effect of the first problem (ORA-02049) once it appears for a couple of times. Can somebody validate this?
    # Though I don't understand JTA well but I don't think this application needs distributed transactions so, I'm thinking of modifying the driver type to non-XA oracle driver. Any advise/pointers/comments on this front is welcome !!!!!!!!
    Thanks
    Guneet Sahai
    Exception Trace
    Dec 27, 2006 4:47:50 PM | com.gisil.themis.db | SEVERE | Unable to load merchant DEL = 911168900164. Reason - java.sql.SQLException: Unexpected exception while enlisting XAConnection java.sql.SQLException: XA error: XAResource.XAER_RMERR start() failed on resource 'themis-ds': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException: Unexpected error during start for XAResource 'themis-ds': Transaction timed out after 29 seconds
    BEA1-252DE51AC930078CA638
    at weblogic.jdbc.wrapper.XA.createException(XA.java:103)
    at weblogic.jdbc.jta.DataSource.start(DataSource.java:753)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1182)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1115)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:274)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:497)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:429)
    at weblogic.jdbc.jta.DataSource.enlist(DataSource.java:1408)
    at weblogic.jdbc.jta.DataSource.refreshXAConnAndEnlist(DataSource.java:1332)
    at weblogic.jdbc.jta.DataSource.getConnection(DataSource.java:440)
    at weblogic.jdbc.jta.DataSource.connect(DataSource.java:396)
    at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:359)
    at com.gisil.themis.db.impl1.DbManagerImpl.isPinValid(DbManagerImpl.java:872)
    at com.gisil.themis.ejb.ThemisBean.isPinValid(ThemisBean.java:185)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl.isPinValid(Themis_aqqc4k_EOImpl.java:207)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl_WLSkel.invoke(Unknown Source)
    at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:517)
    at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:224)
    at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:407)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
    at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:403)
    at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:56)
    at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:934)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
    at weblogic.jdbc.jta.DataSource.enlist(DataSource.java:1413)
    at weblogic.jdbc.jta.DataSource.refreshXAConnAndEnlist(DataSource.java:1332)
    at weblogic.jdbc.jta.DataSource.getConnection(DataSource.java:440)
    at weblogic.jdbc.jta.DataSource.connect(DataSource.java:396)
    at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:359)
    at com.gisil.themis.db.impl1.DbManagerImpl.isPinValid(DbManagerImpl.java:872)
    at com.gisil.themis.ejb.ThemisBean.isPinValid(ThemisBean.java:185)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl.isPinValid(Themis_aqqc4k_EOImpl.java:207)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl_WLSkel.invoke(Unknown Source)
    at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:517)
    at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:224)
    at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:407)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
    at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:403)
    at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:56)
    at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:934)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)

    guneet sahai wrote:
    Hi,
    My name is Guneet and I'm working on an application running on BEA Weblogic Server 9.2 running on a Red Hat Linux box using Oracle 10g as the database. My problem is that recently our code started getting the following exception while updating a database table.
    java.sql.SQLException: [BEA][Oracle JDBC Driver][Oracle]ORA-02049: timeout: distributed transaction waiting for lock
    Application Details
    * Using Stateless Session EJB
    * Only one Business method in this EJB with transaction attribute set to "required"
    * This method executes two select queries & one update query
    * We are using JDBC to access the database.
    * We have configured a Data Source & are using it to get a database connection.
    * Weblogic's Oracle Driver is being used.
    More details
    * The application has been running well since a month.
    * Two days ago,the update query failed with the above error.
    * At that time, a single client was accessing the system.
    * Once this problem occurs, it starts appearing frequently.
    * Eventually a request to get a connection from the Data Source times out & the exception copied at the end is thrown
    * At this stage the application gets stuck and all requests trying to get a connection end up with this exception.
    * Fortunately, Restarting the Weblogic Server gets us out of this problem and transactions resume normally.
    Now my questions are
    # Why is this error happening & what does it mean?
    # It looks like the second exception (unable to get a connection from ds) is an after effect of the first problem (ORA-02049) once it appears for a couple of times. Can somebody validate this?
    # Though I don't understand JTA well but I don't think this application needs distributed transactions so, I'm thinking of modifying the driver type to non-XA oracle driver. Any advise/pointers/comments on this front is welcome !!!!!!!!
    Thanks
    Guneet SahaiHi Guneet. If you want to debug the JTA issue, I suggest opening an official
    support case. They will lead you through producing the JTA debug information.
    However, I believe you are correct that the transaction you describe is
    completely doable with a simple local transaction, so if you were to alter
    your pool to use the non-XA driver, it would probably be faster, simpler,
    and just work.
    Let me know...
    Joe
    >
    Exception Trace
    Dec 27, 2006 4:47:50 PM | com.gisil.themis.db | SEVERE | Unable to load merchant DEL = 911168900164. Reason - java.sql.SQLException: Unexpected exception while enlisting XAConnection java.sql.SQLException: XA error: XAResource.XAER_RMERR start() failed on resource 'themis-ds': XAER_RMERR : A resource manager error has occured in the transaction branch
    javax.transaction.xa.XAException: Unexpected error during start for XAResource 'themis-ds': Transaction timed out after 29 seconds
    BEA1-252DE51AC930078CA638
    at weblogic.jdbc.wrapper.XA.createException(XA.java:103)
    at weblogic.jdbc.jta.DataSource.start(DataSource.java:753)
    at weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1182)
    at weblogic.transaction.internal.XAServerResourceInfo.xaStart(XAServerResourceInfo.java:1115)
    at weblogic.transaction.internal.XAServerResourceInfo.enlist(XAServerResourceInfo.java:274)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:497)
    at weblogic.transaction.internal.ServerTransactionImpl.enlistResource(ServerTransactionImpl.java:429)
    at weblogic.jdbc.jta.DataSource.enlist(DataSource.java:1408)
    at weblogic.jdbc.jta.DataSource.refreshXAConnAndEnlist(DataSource.java:1332)
    at weblogic.jdbc.jta.DataSource.getConnection(DataSource.java:440)
    at weblogic.jdbc.jta.DataSource.connect(DataSource.java:396)
    at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:359)
    at com.gisil.themis.db.impl1.DbManagerImpl.isPinValid(DbManagerImpl.java:872)
    at com.gisil.themis.ejb.ThemisBean.isPinValid(ThemisBean.java:185)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl.isPinValid(Themis_aqqc4k_EOImpl.java:207)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl_WLSkel.invoke(Unknown Source)
    at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:517)
    at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:224)
    at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:407)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
    at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:403)
    at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:56)
    at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:934)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
    at weblogic.jdbc.jta.DataSource.enlist(DataSource.java:1413)
    at weblogic.jdbc.jta.DataSource.refreshXAConnAndEnlist(DataSource.java:1332)
    at weblogic.jdbc.jta.DataSource.getConnection(DataSource.java:440)
    at weblogic.jdbc.jta.DataSource.connect(DataSource.java:396)
    at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:359)
    at com.gisil.themis.db.impl1.DbManagerImpl.isPinValid(DbManagerImpl.java:872)
    at com.gisil.themis.ejb.ThemisBean.isPinValid(ThemisBean.java:185)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl.isPinValid(Themis_aqqc4k_EOImpl.java:207)
    at com.gisil.themis.ejb.Themis_aqqc4k_EOImpl_WLSkel.invoke(Unknown Source)
    at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:517)
    at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:224)
    at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:407)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
    at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:403)
    at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:56)
    at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:934)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)

  • ORA-02049  and Real Application Cluster

    I have 2 site
    first one with a single Oracle Server
    and
    the second one with 2 server with the RAC technology (Real Application Server)
    In the second one (RAC environement) I have the ORA-02049 timeout: distributed transaction waiting for lock when I run my custom software.
    All its ok in the first one.
    do you have some hints about that for me ?
    thanks

    ORA-02049 timeout: distributed transaction waiting for lock
    Cause: Exceeded INIT.ORA DISTRIBUTED_LOCK_TIMEOUT seconds waiting for lock.
    Action: Treat as a deadlock.
    Perhaps you RAC is not handling the transactions with the same speed. I recommend you to increase that value.
    That kind of error comes generally when the transactions consumes more time than specified by that parameter. The network can be one of the causes of it. As I told you, I recommend you highly to increase that parameter.
    Joel Pérez
    http://www.oracle.com/technology/experts

  • Works in sql not in apex: ORA-02049 distributed transaction waiting lock

    Hi,
    I get this error
    failed to parse SQL query:
    ORA-02049: timeout: distributed transaction waiting for lockwhen trying to run this query from it's page. But it works fine if I run it in the SQL console...
    failed to parse SQL query:
    ORA-select distinct n.notif_no,
           n.maint_work_centre,
           n.maint_work_centre_text,
           n.raised_by,
           n.notif_text,
           (select  (SAP_LONG_TEXT.NOTIFICATION_TEXT_1||SAP_LONG_TEXT.NOTIFICATION_TEXT_2||SAP_LONG_TEXT.NOTIFICATION_TEXT_3||SAP_LONG_TEXT.NOTIFICATION_TEXT_4||SAP_LONG_TEXT.NOTIFICATION_TEXT_5||SAP_LONG_TEXT.NOTIFICATION_TEXT_6||SAP_LONG_TEXT.NOTIFICATION_TEXT_7||SAP_LONG_TEXT.NOTIFICATION_TEXT_8||SAP_LONG_TEXT.NOTIFICATION_TEXT_9||SAP_LONG_TEXT.NOTIFICATION_TEXT_10||SAP_LONG_TEXT.NOTIFICATION_TEXT_11||SAP_LONG_TEXT.NOTIFICATION_TEXT_12||SAP_LONG_TEXT.NOTIFICATION_TEXT_13||SAP_LONG_TEXT.NOTIFICATION_TEXT_14||SAP_LONG_TEXT.NOTIFICATION_TEXT_15||SAP_LONG_TEXT.NOTIFICATION_TEXT_16||SAP_LONG_TEXT.NOTIFICATION_TEXT_17||SAP_LONG_TEXT.NOTIFICATION_TEXT_18||SAP_LONG_TEXT.NOTIFICATION_TEXT_19||SAP_LONG_TEXT.NOTIFICATION_TEXT_20||SAP_LONG_TEXT.NOTIFICATION_TEXT_21||SAP_LONG_TEXT.NOTIFICATION_TEXT_22||SAP_LONG_TEXT.NOTIFICATION_TEXT_23||SAP_LONG_TEXT.NOTIFICATION_TEXT_24||SAP_LONG_TEXT.NOTIFICATION_TEXT_25||SAP_LONG_TEXT.NOTIFICATION_TEXT_26||SAP_LONG_TEXT.NOTIFICATION_TEXT_27||SAP_LONG_TEXT.NOTIFICATION_TEXT_28||SAP_LONG_TEXT.NOTIFICATION_TEXT_29||SAP_LONG_TEXT.NOTIFICATION_TEXT_30||SAP_LONG_TEXT.NOTIFICATION_TEXT_31||SAP_LONG_TEXT.NOTIFICATION_TEXT_32||SAP_LONG_TEXT.NOTIFICATION_TEXT_33||SAP_LONG_TEXT.NOTIFICATION_TEXT_34||SAP_LONG_TEXT.NOTIFICATION_TEXT_35||SAP_LONG_TEXT.NOTIFICATION_TEXT_36||SAP_LONG_TEXT.NOTIFICATION_TEXT_37||SAP_LONG_TEXT.NOTIFICATION_TEXT_38||SAP_LONG_TEXT.NOTIFICATION_TEXT_39||SAP_LONG_TEXT.NOTIFICATION_TEXT_40||SAP_LONG_TEXT.NOTIFICATION_TEXT_41||SAP_LONG_TEXT.NOTIFICATION_TEXT_42||SAP_LONG_TEXT.NOTIFICATION_TEXT_43||SAP_LONG_TEXT.NOTIFICATION_TEXT_44||SAP_LONG_TEXT.NOTIFICATION_TEXT_45||SAP_LONG_TEXT.NOTIFICATION_TEXT_46||SAP_LONG_TEXT.NOTIFICATION_TEXT_47||SAP_LONG_TEXT.NOTIFICATION_TEXT_48||SAP_LONG_TEXT.NOTIFICATION_TEXT_49||SAP_LONG_TEXT.NOTIFICATION_TEXT_50) from sap_long_text@genadm where sap_long_text.notification = n.notif_no) "long",
           n.notif_date,
           n.funct_loc,
           n.order_no,
           n.notif_status,
           n.room,
           n.notif_type
    from   notifications@amt n, SAP_LONG_TEXT@genadm
    where  instr(':'||:P9_NOTIFTYPE||':',':'||n.NOTIF_TYPE||':')>0 and
           instr (':'||:P9_SITE||':',':'||n.site||':') > 0 and
           n.notif_date BETWEEN :P9_DATEFROM and :P9_DATETO and
           n.notif_status not like '%NOCO%'I've had this error before but I don't remember why/what happened. The page has been working fine, the error just randomly cropped up today.
    And a secondary question, is there a better way to write the query (it's a copy/paste from an older query). That select within the select is ugly...

    Hello,
    Take a look at the following thread -
    help ORA-02049
    Is it really necessary that you always query across the DBLink? Is using local materialized views not an option for you?
    John.
    http://jes.blogs.shellprompt.net
    http://apex-evangelists.com

  • OWB9.0.4-- ORA-02049: timeout: distributed transaction waiting for lock

    I'm running a simple mapping that copies all columns of data (using a filter on date for just current records) from one table in SQL Server into a staging table on my Oracle DW schema. It's using a dblink with transparent gateway for SQL Server, which works fine from SQL*plus.
    The map is in default mode (bulk-failoverto-row) with bulk size and commit frequency = 1000.
    The audit details show the first 1000 rows selected on the source, with an error on both the source and target tables:
    Target--
    ORA-02049: timeout: distributed transaction waiting for lock
    Source--
    ORA-01002: fetch out of sequence ORA-02063: preceding line from INTERGRATION@JXNSQL01
    (INTERGRATION@JXNSQL01 is the dblink name)
    Any ideas on how I can clear this up?
    Thanks,
    Paul

    Hi,
    After having upgraded to 9.0.4 (from 9.0.3) I'm running into exactly the same problems with some of my mappings. Actually I don't get any rows transferred from the mappings that fail.
    Out of 7 mappings, 3 worked just liked before while the 4 others just keep on running until I cancel them and I then see the BUSY/ORA-02049 in the Audit Browser.
    When comparing the mappings I see that the 3 that works all use some custom Procedures I have made.
    The 4 that doesn't work are all very simple - one of them just loads all the content from a table with two columns in my source to another table with two columns in my target! Two of the other mappings that doesn't work includes some simple CASE-expressions.
    Both my source and my target resides in a Oracle 9.2.0.3 database (not the same).
    Regards,
    Bent Madsen

  • Help ORA-02049

    HELP HELP HELP!!
    Following error on Oracle 8.1.7
    SQR 5528) ORACLE OCIStmtExecute error 2049 in cursor 38:
    ORA-02049: timeout: distributed transaction waiting for lock
    ORA-02063: preceding line from XAPPPRD
    Error on line 3155:
    (SQR 3735) Could not execute SQL.
    SQR for PeopleSoft: Program Aborting.
    Thanks
    jason

    ORA-02049 timeout: distributed transaction waiting for lock
    Cause: Exceeded INIT.ORA DISTRIBUTED_LOCK_TIMEOUT seconds waiting for lock.
    Action: Treat as a deadlock.
    Joel Pérez
    http://otn.oracle.com/experts

  • DatabaseError: ORA-02049: timeout: distributed transaction waiting for lock

    Hi all
    There is script running in my database 'A' that will select some data from tables in other database through DBLINK and update some tables too. The script which 6 I am running for the past 6 monts succesfully. Yesterday I got error saying that,
    DatabaseError: ORA-02049: timeout: distributed transaction waiting for lock
    ORA-02063: preceding line from test
    I have tested the Link and its active no issues in DBLINk
    I understand the objects which I am accessing the table in locked mode,
    SQL> select OBJECT_ID,SESSION_ID,PROCESS,LOCKED_MODE from v$locked_object where
    SESSION_ID=121;
    OBJECT_ID SESSION_ID PROCESS LOCKED_MODE
    77391 121 21394 3
    i
    I killed the session 121 and in v$session status is Killed, but I am getting the same error repeating while running the script. And the session_id is still in locked_mode.
    Could please add some light on this?
    -Thanks
    Antony

    Hi,
    I have killed the session which caused blocking and the status is KILLED for the past two days. But still the object is in locked mode
    SQL> select OBJECT_ID,SESSION_ID,PROCESS,LOCKED_MODE from v$locked_object where
    SESSION_ID=121;
    OBJECT_ID SESSION_ID PROCESS LOCKED_MODE
    77391 121 21394 3
    How would I resolve this any idea
    -Thanks & Cheers
    Antony

  • Please help for ORA-02049 - Timeout error

    Hi All,
    we have got a reporting DB and 14+ Application DBs, the data is extracted from all the application databases (DBs) and dumped into the common tables of reporting database. While inserting and updating the common reporting tables the other jobs gets timeout error and fails. We daily face this failure problem (error: ORA-02049 - Timeout error distributed transaction waiting for lock) for almost 10-15 times.
    Can you please help me out in resolving and getting the permanent solution for this problem.
    Thanks in advance.

    Thanks Kamal,
    as mentioned above, I have got Oracle,Java,Unix environment. Autosys jobs are scheduled through out the day.
    Mechanism : Autosys job triggers the action at specified time, Unix code calls oracle packaged procedure, extracts data and puts into the common reporting table from this data java code formats the report output.
    There are separate reporting jobs for all instances though the report is same but for different locations(14 DB instances).
    and all these reporting jobs dump data into common reporting table, data can be differentiated on the hub or location.
    But if one job is running for first instance then second job waits for the lock and fails after 2 mins.
    I have to avoid this situation, I hold I am able to explain the situation.

  • Error ORA-02049 in Oracle 8.1.6.0

    Hello All
    we comeacross error ORA 2049. i.e distributed_lock_timeout has occured ,while
    executing a procedure.
    When we checked with the initial parameters it is found to be at a maximum.
    We are using Oracle 8.1.6.0 on IBM AIX
    (multiple instances).
    Can anyone give some suggestions.
    Ramanathan.PS
    null

    Dr. Chaudhary,
    Based on the [lack of] information you have provided, I can only make some guesses. To increase the chances of getting an answer, I suggest you post the following information:
    1. Entire error message and stack trace you are getting.
    2. The part of your java code where the problem is occurring.
    3. Oracle database version you are using.
    4. Java version you are using.
    5. JDBC driver you are using.
    6. Platform you are using.
    Good Luck,
    Avi.

  • Setting transaction isolation level rises ORA-02089 error

    Hello
    We have configured a distributed transaction in our application server and
    we are using openjpa 1.2.1 and Glassfish application server and Oracle 11g as DB server. Although the default behavior of transaction locking must be optimistic,
    it seems that pessimistic locking has been happened.
    It is found that Row Lock contention happens in a specific table.
    This is the exception :
    java.sql.SQLException: ORA-02049: timeout: distributed transaction waiting for lock
    Already all the following properties have been set for openjpa.
    1. <persistence-unit name="JPXA" transation-type="JTA">
    2. <property name="openjpa.TransactionMode" value="managed"/>
    You can try a plug-in string to lookup the TM in JNDI (the value is the JNDI name of GlassFish TM as per Google search)
    3. <property name="openjpa.ManagedRuntime"
    value="jndi(TransactionManagerName=java:appserver/TransactionManager)"/>
    Following searching about this locking problem, we found that we should add two more properties for openjpa as listed below.
    <property name="openjpa.LockManager" value="version" />
    <property name="openjpa.jdbc.TransactionIsolation" value="read-committed" />
    but this time by setting the transaction isolation level, we have got another error: org.apache.openjpa.persistence.PersistenceException: ORA-02089: COMMIT is not allowed in a subordinate session.
    Thanks for any help.
    Regards,
    Sargol

    Hello
    We have configured a distributed transaction in our application server and
    we are using openjpa 1.2.1 and Glassfish application server and Oracle 11g as DB server. Although the default behavior of transaction locking must be optimistic,
    it seems that pessimistic locking has been happened.
    It is found that Row Lock contention happens in a specific table.
    This is the exception :
    java.sql.SQLException: ORA-02049: timeout: distributed transaction waiting for lock
    Already all the following properties have been set for openjpa.
    1. <persistence-unit name="JPXA" transation-type="JTA">
    2. <property name="openjpa.TransactionMode" value="managed"/>
    You can try a plug-in string to lookup the TM in JNDI (the value is the JNDI name of GlassFish TM as per Google search)
    3. <property name="openjpa.ManagedRuntime"
    value="jndi(TransactionManagerName=java:appserver/TransactionManager)"/>
    Following searching about this locking problem, we found that we should add two more properties for openjpa as listed below.
    <property name="openjpa.LockManager" value="version" />
    <property name="openjpa.jdbc.TransactionIsolation" value="read-committed" />
    but this time by setting the transaction isolation level, we have got another error: org.apache.openjpa.persistence.PersistenceException: ORA-02089: COMMIT is not allowed in a subordinate session.
    Thanks for any help.
    Regards,
    Sargol

  • How to find out the user who locked the record

    i can't delete a particular record from a table while executing the delete command its showing an error specifying
    that "ORA-02049: timeout: distributed transaction waiting for lock"
    syntax i used
    delete from <table_name> where <column_name>='<value>'

    Hi,
    select username,lockwait,process,sql_hash_value from v$session. Find the user who is having more lock wait
    See the lock wait has more value notedown has_value
    select sql_text from v$sqltext where has_value="Noted value " find the query whether your table is calling by the user.

  • Error while linking the user

    Hi,
    I have configured the trusted reconciliation for OID.
    1. I have created the variables in RO and mapped them in the Process Definition.
    2. Then I created the reconciliation rule "User Login Equals User ID" and mapped the User ID to uid in the recon lookup. I have made the rule active.
    3. I clicked on the create reconciliation profile and restarted the server.
    I am able to get the values in the OIM events but from there its not linking to the user. The user ID that I am receiving in the event is absolutely the same as that of the User Login in OIM. The error I am receiving in the logs are as below.
    <Aug 29, 2012 11:40:00 PM EST> <Error> <oracle.iam.reconciliation.impl> <IAM-5010000> <Generic Error/Information: {0}
    oracle.iam.platform.utils.SuperRuntimeException: java.sql.SQLSyntaxErrorException: ORA-02049: timeout: distributed transaction waiting for lock
    ORA-06512: at "TST2B_OIM.OIM_SP_RECONBLKUSERCRUD", line 3844
    ORA-06512: at "TST2B_OIM.OIM_SP_RECONBLKUSRMLSWRAPPER", line 71
    ORA-06512: at line 1
    at oracle.iam.reconciliation.dao.DBCall.execute(DBCall.java:24)
    at oracle.iam.reconciliation.dao.ReconActionDao.processSPCall(ReconActionDao.java:1316)
    at oracle.iam.reconciliation.dao.ReconActionDao.executeBulkUserMatchCRUD(ReconActionDao.java:686)
    at oracle.iam.reconciliation.impl.UserHandler.executeBulkCUD(UserHandler.java:568)
    at oracle.iam.reconciliation.impl.BaseEntityTypeHandler.process(BaseEntityTypeHandler.java:34)
    at oracle.iam.reconciliation.impl.ActionEngine.processBatch(ActionEngine.java:129)
    at oracle.iam.reconciliation.impl.ActionEngine.execute(ActionEngine.java:90)
    at oracle.iam.reconciliation.impl.ActionTask.execute(ActionTask.java:72)
    at oracle.iam.platform.async.impl.TaskExecutor.executeUnmanagedTask(TaskExecutor.java:100)
    at oracle.iam.platform.async.impl.TaskExecutor.execute(TaskExecutor.java:70)
    at oracle.iam.platform.async.messaging.MessageReceiver.onMessage(MessageReceiver.java:68)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
    at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
    at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at $Proxy334.onMessage(Unknown Source)
    at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:466)
    at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:371)
    at weblogic.ejb.container.internal.MDListener.onMessage(MDListener.java:327)
    at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:4659)
    at weblogic.jms.client.JMSSession.execute(JMSSession.java:4345)
    at weblogic.jms.client.JMSSession.executeMessage(JMSSession.java:3821)
    at weblogic.jms.client.JMSSession.access$000(JMSSession.java:115)
    at weblogic.jms.client.JMSSession$UseForRunnable.run(JMSSession.java:5170)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Caused By: java.sql.SQLSyntaxErrorException: ORA-02049: timeout: distributed transaction waiting for lock
    ORA-06512: at "TST2B_OIM.OIM_SP_RECONBLKUSERCRUD", line 3844
    ORA-06512: at "TST2B_OIM.OIM_SP_RECONBLKUSRMLSWRAPPER", line 71
    ORA-06512: at line 1
    at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:95)
    at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:135)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:210)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:473)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:423)
    at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:1095)
    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:201)
    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:1036)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1379)
    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3568)
    at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3739)
    at oracle.jdbc.driver.OracleCallableStatement.execute(OracleCallableStatement.java:8150)
    at oracle.jdbc.driver.OraclePreparedStatementWrapper.execute(OraclePreparedStatementWrapper.java:1535)
    at weblogic.jdbc.wrapper.PreparedStatement.execute(PreparedStatement.java:99)
    at oracle.iam.reconciliation.dao.ReconActionDao$1ReconDBCall.command(ReconActionDao.java:1288)
    at oracle.iam.reconciliation.dao.ReconActionDao$1ReconDBCall.command(ReconActionDao.java:1271)
    at oracle.iam.reconciliation.dao.DBCall.execute(DBCall.java:17)
    at oracle.iam.reconciliation.dao.ReconActionDao.processSPCall(ReconActionDao.java:1316)
    at oracle.iam.reconciliation.dao.ReconActionDao.executeBulkUserMatchCRUD(ReconActionDao.java:686)
    at oracle.iam.reconciliation.impl.UserHandler.executeBulkCUD(UserHandler.java:568)
    at oracle.iam.reconciliation.impl.BaseEntityTypeHandler.process(BaseEntityTypeHandler.java:34)
    at oracle.iam.reconciliation.impl.ActionEngine.processBatch(ActionEngine.java:129)
    at oracle.iam.reconciliation.impl.ActionEngine.execute(ActionEngine.java:90)
    at oracle.iam.reconciliation.impl.ActionTask.execute(ActionTask.java:72)
    at oracle.iam.platform.async.impl.TaskExecutor.executeUnmanagedTask(TaskExecutor.java:100)
    at oracle.iam.platform.async.impl.TaskExecutor.execute(TaskExecutor.java:70)
    at oracle.iam.platform.async.messaging.MessageReceiver.onMessage(MessageReceiver.java:68)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
    at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
    at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
    at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
    at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
    at $Proxy334.onMessage(Unknown Source)
    at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:466)
    at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:371)
    at weblogic.ejb.container.internal.MDListener.onMessage(MDListener.java:327)
    at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:4659)
    at weblogic.jms.client.JMSSession.execute(JMSSession.java:4345)
    at weblogic.jms.client.JMSSession.executeMessage(JMSSession.java:3821)
    at weblogic.jms.client.JMSSession.access$000(JMSSession.java:115)
    at weblogic.jms.client.JMSSession$UseForRunnable.run(JMSSession.java:5170)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:173
    Please let me know how to get this resolved. Thanks a lot.

    It seems there is problem to get LOCK. In oracle we have DISTRIBUTED_LOCK_TIMEOUT parameter to control this. You can verify similar parmeter in Weblogic console and increase the LOCK_TIMEOUT. restart all servers along with Database. Even if you don't find any parameter like that. just restart all servers including DB

  • JDBC Exception while calling a web-service

    Hi all,
    We are getting the following JDBC Driver Timeout Exception while calling an external web-service..
    An exception occurred while executing a transaction. Details: An error occurred while accesing the database. Detail:SQL statement: ' SELECT INSTANCEDATA, PROCESSID, INSTID, THREADID, NAME, PARENTTHREAD, PRIORITY, CREATIONTIME, AUTHOR, PARTICIPANT, NEXTPARTICIPANT, PROCESSDEADLINE, ACTIVITYDEADLINE, RECEIVETIME, ACTIVITYNAME, NTHREADS, CTHREADS, FCTHREAD, TOTALTHREADS, STATE, SOURCEACTIVITYNAME, ROLEIN, PENDINGITEMID, LASTRESULT, ITEMDEADLINE, NCHANGES , NREMARKS, NATTACHMENTS, HASPARTFORROLE,MICROACTIVITYNAME FROM PPROCINSTANCE WHERE PROCESSID = 11AND INSTID = 10 AND THREADID = 0 FOR UPDATE' Caused by: [BEA][Oracle JDBC Driver][Oracle]ORA-02049: timeout: distributed transaction waiting for lock fuego.transaction.DatabaseException:
    How do we resolve this exception?
    We have increased the JTA timeout to 120 seconds.. in the engine..
    Our process is deployed on Weblogic Server

    Looks like specific record for the Instance id 10 is locked in the Engine table. I am not quite sure, what kind of Business scenraio you executed to end up in this issue.
    But you can try restarting the BPM engine or check with the Oracle DBA to see any lock on the rows in Engine database and perform required unlocking operations.
    -Lovin.V

  • Timeout when inserting row in a locked table

    How can I set the timeout before an INSERT statement fails with error ORA-02049 (timeout: distributed transaction waiting for lock) when the entire table has been lock with LOCK TABLE .
    Documentation says to modify DISTRIBUTED_LOCK_TIMEOUT parameter, but it is obsolete in Oracle 8i.
    Any idea ???

    You could set an alarm() in a signal. Then on return (for whatever reason) you clear the alarm, inspect the return code of the sql execute call and determine what happened (i.e. did the transaction completed or did the alarm get you).
    Hope it helps.
    -Lou
    [email protected]
    How can I set the timeout before an INSERT statement fails with error ORA-02049 (timeout: distributed transaction waiting for lock) when the entire table has been lock with LOCK TABLE .
    Documentation says to modify DISTRIBUTED_LOCK_TIMEOUT parameter, but it is obsolete in Oracle 8i.
    Any idea ???

  • Time-out problem in Sync. replication

    When I would like to add tables to materialized view group in updatable MV in synchronous mode , I encount
    below error :
    ORA-02049 : Timeout : Distributed transaction waiting for lock
    By increasing the time-out of lock , nothing happens and error still exists.
    Thanks in advanced to help me.

    Hi Pat,
    How many record did you copy ??
    Could you restrict the copy in not 1 package ??
    Package per package ...
    I suggest you ..
    e.g. you have restriction by a 0CALMONTH / something ..
    Then,
    You can copy e.g. for January to March, then March to August, etc.
    You can automate it by planning sequence.
    Hopefully it can help you a lot.
    Regards,
    Niel.
    thanks for the points you choose to assign.

Maybe you are looking for

  • How do I transfer my files from Quicken 13 (Windows) to Lion Compatible Quicken 2007

    How do I transfer my files from Quicken 13 (Windows) to Lion compatbile Quicken 2007

  • Help validating param fields with Javascript

    Hi, Rpt Escapes: B4 Form Values, I added a javascript that validates the entered date_ranges(date_from -- date_to) -- must not be > 30 days. If I used that javascript in one of the param fields (web_settings:: Additional HTML = onChange="show_alert(t

  • How to bind to an Hslider with multiple thumbs?

    OK folks, I have a Hslider with three thumbs. One thumb for the min of a range, a thumb for the value I want to bind, and the third thumb for the max of a range. My problem is data binding does not work when i use the VALUES array property of the Hsl

  • Programatically Assigning Column Value Based on Another Column

    I have a problem as follows: My database table has the following setup: There may be many gift numbers the same, however many different recipient numbers for each gift. The receipient number should increment from 1-X based on the gift number, for exa

  • Where  do the scratches occur?

    Where do the scratches occur? On the screen? On the body? Both? If I can get away with just a screen protector only I'd rather do that as I really love the finish on the black body. But if the body scratches easily too then I might as well go for the