Jboss Messaging Clustering in Jboss 4.2.3 using Oracle Datasource
gibberishmock Sep 7, 2012 1:16 AMHello all i hope this is the correct forum to be disscussing this topic.
I am currently trying to use JBM with Jboss AS with Oracle as shared database for clustering. The version of the components are:
- JBM 1.4.5
- Jboss 4.2.3
- Oracle driver : ojdbc14-10.2.0.1.0
I followed the steps described in the JBM docs (http://docs.jboss.org/jbossmessaging/docs/userguide-1.4.5.GA/html/installation.html#install.manual) and then tested the installation as described in the "Installation Validation" portion, all of the test succeeded. But the problem arises when i try to restart the server after sometime. The stactrace shows the following error:
2012-09-06 18:14:35,041 DEBUG [org.jboss.system.ServiceController] Starting dependent components for: jboss.ejb:service=EJBTimerService,persistencePolicy=database dependent components: [] 2012-09-06 18:14:35,041 DEBUG [org.jboss.system.ServiceController] starting service jboss.messaging:service=PersistenceManager 2012-09-06 18:14:35,041 DEBUG [org.jboss.messaging.core.jmx.JDBCPersistenceManagerService] Starting jboss.messaging:service=PersistenceManager 2012-09-06 18:14:35,079 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_DUAL (DUMMY INTEGER, PRIMARY KEY (DUMMY)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:468)........................ 2012-09-06 18:14:35,085 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_MSG_REF (MESSAGE_ID INTEGER, CHANNEL_ID INTEGER, TRANSACTION_ID INTEGER, STATE CHAR(1), ORD INTEGER, PAGE_ORD INTEGER, DELIVERY_COUNT INTEGER, SCHED_DELIVERY INTEGER, PRIMARY KEY(MESSAGE_ID, CHANNEL_ID)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137)........................... 2012-09-06 18:14:35,094 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE INDEX JBM_MSG_REF_TX ON JBM_MSG_REF (TRANSACTION_ID, STATE) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137)............................ 2012-09-06 18:14:35,099 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_MSG (MESSAGE_ID INTEGER, RELIABLE CHAR(1), EXPIRATION INTEGER, TIMESTAMP INTEGER, PRIORITY INTEGER, TYPE INTEGER, HEADERS BLOB, PAYLOAD BLOB, PRIMARY KEY (MESSAGE_ID)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257).............................. 2012-09-06 18:14:35,103 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_TX (NODE_ID INTEGER, TRANSACTION_ID INTEGER, BRANCH_QUAL RAW(254), FORMAT_ID INTEGER, GLOBAL_TXID RAW(254), PRIMARY KEY (TRANSACTION_ID)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)...................................... 2012-09-06 18:14:35,107 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_COUNTER (NAME VARCHAR2(255), NEXT_ID INTEGER, PRIMARY KEY(NAME)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257).................................. 2012-09-06 18:14:35,111 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_ID_CACHE (NODE_ID INTEGER, CNTR INTEGER, JBM_ID VARCHAR2(255), PRIMARY KEY(NODE_ID, CNTR)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)................................. 2012-09-06 18:14:35,145 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_USER (USER_ID VARCHAR2(32) NOT NULL, PASSWD VARCHAR2(32) NOT NULL, CLIENTID VARCHAR2(128), PRIMARY KEY(USER_ID)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137)................................. 2012-09-06 18:14:35,150 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_ROLE (ROLE_ID VARCHAR2(32) NOT NULL, USER_ID VARCHAR2(32) NOT NULL, PRIMARY KEY(USER_ID, ROLE_ID)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)............................. 2012-09-06 18:14:35,157 DEBUG [org.jboss.jms.server.plugin.JDBCJMSUserManager] Failed to execute INSERT INTO JBM_ROLE (ROLE_ID, USER_ID) VALUES ('subscriber','john') java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (JBOSSDB.SYS_C001169625) violated at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:185) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)...................................... 2012-09-06 18:14:35,224 DEBUG [org.jboss.jms.server.plugin.JDBCJMSUserManager] Failed to execute INSERT INTO JBM_USER (USER_ID, PASSWD, CLIENTID) VALUES ('john', 'needle', 'DurableSubscriberExample') java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (JBOSSDB.SYS_C001169622) violated at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:185) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:468)...................................... 2012-09-06 18:14:35,243 DEBUG [org.jboss.jms.server.plugin.JDBCJMSUserManager] Failed to execute INSERT INTO JBM_USER (USER_ID, PASSWD) VALUES ('j2ee', 'j2ee') java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (JBOSSDB.SYS_C001169622) violated at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:185) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:468)...................................... 2012-09-06 18:14:35,247 DEBUG [org.jboss.jms.server.plugin.JDBCJMSUserManager] Failed to execute INSERT INTO JBM_USER (USER_ID, PASSWD) VALUES ('guest', 'guest') java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (JBOSSDB.SYS_C001169622) violated at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:185) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)....................... 2012-09-06 18:14:35,616 DEBUG [org.jboss.messaging.core.impl.JDBCSupport] Failed to execute: CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR2(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR2(255), COND VARCHAR2(1023), SELECTOR VARCHAR2(1023), CHANNEL_ID INTEGER, CLUSTERED CHAR(1), ALL_NODES CHAR(1), PRIMARY KEY(POSTOFFICE_NAME, NODE_ID, QUEUE_NAME)) java.sql.SQLSyntaxErrorException: ORA-00955: name is already used by an existing object at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:221) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:257)......................... Caused by: java.sql.SQLException: OALL8 is in an inconsistent state at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:120) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:137) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:250) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:330) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:355) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:598) at oracle.jdbc.driver.T4C8Oall.marshal(T4C8Oall.java:495) at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:202) at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:1039) at oracle.jdbc.driver.T4CPreparedStatement.executeMaybeDescribe(T4CPreparedStatement.java:1146) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1472) at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3889) at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3959) at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:4515) at oracle.jdbc.OracleDatabaseMetaData.getTables(OracleDatabaseMetaData.java:5984) at org.jboss.ejb.plugins.cmp.jdbc.SQLUtil.tableExists(SQLUtil.java:1075) ... 113 more ............... 2012-09-06 18:14:52,050 WARN [org.jboss.system.ServiceController] Problem starting service jboss:service=KeyGeneratorFactory,type=HiLo org.jboss.deployment.DeploymentException: Error while checking if table aleady exists HILOSEQUENCES; - nested throwable: (java.sql.SQLException: OALL8 is in an inconsistent state) at org.jboss.ejb.plugins.cmp.jdbc.SQLUtil.tableExists(SQLUtil.java:1082) at org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory.createTableIfNotExists(HiLoKeyGeneratorFactory.java:366) at org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory.initSequence(HiLoKeyGeneratorFactory.java:307) at org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory.startService(HiLoKeyGeneratorFactory.java:281) at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289) at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)......
I also searched in oracle forums for this and found(http://asanga-pradeep.blogspot.com/2008/06/oall8-is-in-inconsistent-state-with.html) this. And even after switching the ojdbc driver version from "ojdbc14-10.2.0.1.0" to "ojdbc6_g-11.1.0.7.0" is still get the same error. But if i run the jboss nodes after clearing the tables it works fine. Don't know what is the issues here so hope someone can help me with this problem.
Regards.