eclipse-ee4j / glassfish

Eclipse GlassFish
https://eclipse-ee4j.github.io/glassfish/
377 stars 143 forks source link

[regression] Admincli delegated recovery failure with oracle db #15561

Closed glassfishrobot closed 13 years ago

glassfishrobot commented 13 years ago

Admincli delegated recovery failure with oracle db

glassfish-3.1-b37.zip

Admincli Delegated Recovery with a GF instance crash http://agni-1.us.oracle.com/asqe-logs/export1/v3.1/docs/sqe/txn/GF31TXRecoveryTestSpec.html TX_01R failed with oracle db on build 37 promoted, i.e. DB_A: oralce DB_B: derby

The same test passed previously with the oracle db configuration for recovery in http://java.net/jira/browse/GLASSFISH-13837

The test passed on build 37 promoted if DB_A is derby too.

I will provide test details next.

Environment

Solaris and Linux

Affected Versions

[3.1]

glassfishrobot commented 5 years ago
glassfishrobot commented 13 years ago

@glassfishrobot Commented sherryshen said: b37p TX_01R failed (cliweb2 test2) --To setup sqe cluster env, please see http://agni-1.us.oracle.com/JSPWiki/Wiki.jsp?page=V31TXInstruction --To setup databases, do "ant startTxDerby" and "ant ee oracle4-setup" in appserver-sqe dir --To reproduce the issue: do "ant ee oracle4 setup build deploy run_test2" in in appserver-sqe/pe/transaction/recovery/cliweb2 dir

The server.log files are saved in http://agni-1.us.oracle.com/net/asqe-logs/export1/v3.1/Results/build37/tx/15561

From in2 log, XAException was observed before [2] [#|2011-01-13T11:57:19.766-0800|WARNING|glassfish3.1| javax.enterprise.system.core.transaction.com.sun.jts.CosTransactions|_ThreadID=183;_ThreadName=Thread-1;|

javax.transaction.xa.XAException at oracle.jdbc.xa.OracleXAResource.recover(OracleXAResource.java:638) at com.sun.gjc.spi.XAResourceImpl.recover(XAResourceImpl.java:179) at com.sun.enterprise.transaction.jts.recovery.OracleXAResource.recoverList(OracleXAResource.java:115) at com.sun.enterprise.transaction.jts.recovery.OracleXAResource.recover(OracleXAResource.java:89) at com.sun.jts.CosTransactions.RecoveryManager.getInDoubtXids(RecoveryManager.java:883) at com.sun.jts.CosTransactions.RecoveryManager.proceedWithXARecovery(RecoveryManager.java:977) at com.sun.jts.CosTransactions.RecoveryManager.recover(RecoveryManager.java:476) at com.sun.jts.CosTransactions.ResyncThread.run(RecoveryManager.java:1847)

[#|2011-01-13T11:57:22.771-0800|WARNING|glassfish3.1|javax.enterprise.system.core. transaction.com.sun.jts.utils.RecoveryHooks|_ThreadID=173;_ThreadName=Thread-1;| JTS5057: FailPoint : [2]|#]

From in2 log, exceptions, and after recovery, data in DB_A (oracle) are missed from verification.

[#|2011-01-13T11:58:22.847-0800|INFO|glassfish3.1|javax.enterprise.system.std.com.sun. enterprise.server.logging|_ThreadID=179;_ThreadName=Thread-1;| -------verifyxa, DB_A: 0; DB_B: 3|#]

glassfishrobot commented 13 years ago

@glassfishrobot Commented mvatkina said: Reassigning back to Sherry to check the Oracle permissions. E.g. this page http://www-01.ibm.com/support/docview.wss?rs=0&q1=3979190&uid=swg21196663&loc=en_US&cs=utf-8&cc=us&lang=en that says that ( "-3" in our logs means XAER_RMERR) granting correct permissions solves the problem.

Please make sure you remove transaction logs and restart the server when you try again to have a clean run (see the 2nd solution in the link)

glassfishrobot commented 13 years ago

@glassfishrobot Commented sherryshen said: The same test passed on v3.1 b37 promoted on another oracle db.

Based on the discussions and suggestions, I tried to configure this oracle db with sqlplus and user of system. It failed with a privilege error.

SQL> grant sys.dba_pending_transactions to CORETEST1; grant sys.dba_pending_transactions to CORETEST1 * ERROR at line 1: ORA-00990: missing or invalid privilege

Then, I used sqlplus and the user of sysdba.

SQL*Plus: Release 11.1.0.6.0 - Production on Tue Jan 18 11:31:25 2011 Copyright (c) 1982, 2007, Oracle. All rights reserved. SQL> SQL> grant select on sys.dba_pending_transactions to CORETEST1; Grant succeeded. SQL> grant execute on sys.dbms_system to CORETEST1; Grant succeeded. SQL> grant select on sys.pending_trans$ to CORETEST1; Grant succeeded. SQL> grant select on sys.dba_2pc_neighbors to CORETEST1; Grant succeeded. SQL> grant select on sys.dba_2pc_pending to CORETEST1; Grant succeeded. SQL> grant execute on sys.dbms_xa to CORETEST1; Grant succeeded. SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options

glassfishrobot commented 13 years ago

@glassfishrobot Commented ai109478 said: Requesting Marina to investigate why the tests are failing after b37? Supporting Oracle DB for Tx recovery is important for 3.1 release.

glassfishrobot commented 13 years ago

@glassfishrobot Commented ai109478 said: Based on latest input from quality team, looks like this feature is working with some specific settings. We will need to document those steps. Please file a doc bug before closing this.

glassfishrobot commented 13 years ago

@glassfishrobot Commented mvatkina said: it was a database setup error. recovery works when the database is correctly set up for recovery

glassfishrobot commented 13 years ago

@glassfishrobot Commented sherryshen said: The tests passed oracle 11.1 database with the setting in #13837 and an additional setting suggested by Marina, grant select on sys.dba_2pc_pending to CORETEST1; Transfer this bug to docs for addressing the setting change. Hope that Marina can help to evaluate or provide the content.

glassfishrobot commented 13 years ago

@glassfishrobot Commented junesm said: Added the extra grant statement to the Admin Guide chapter on transactions.

glassfishrobot commented 13 years ago

@glassfishrobot Commented sherryshen said: verified the fix in docs. Administration Guide Chapter 18, Administering Transactions Oracle Setup for Transaction Recovery. http://java.net/jira/browse/GLASSFISH-13837 Oracle Setup http://java.net/jira/browse/GLASSFISH-15561 Oracle Setup

glassfishrobot commented 13 years ago

@glassfishrobot Commented Was assigned to junesm

glassfishrobot commented 7 years ago

@glassfishrobot Commented This issue was imported from java.net JIRA GLASSFISH-15561

glassfishrobot commented 13 years ago

@glassfishrobot Commented Reported by sherryshen

glassfishrobot commented 13 years ago

@glassfishrobot Commented Marked as fixed on Tuesday, February 1st 2011, 3:33:31 am