Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-3561

ORA-00310 when online redo log is archived and replaced by redo log with new sequence

    XMLWordPrintable

Details

    Description

      We are running Debezium 1.5 on Kafka 2.6. In this we are running 4 parallel connectors that connect to the same Oracle 19c database. Each connector has a specific set of whitelisted tables (each having between 5 to 30 tables in its include list). As a log mining strategy we are using online_catalog, and are setting log.mining.archive.log.hours to 4. This is a security enabled Kafka cluster with SASL_SSL.
       
      Last night we had 1 out of the 4 connectors fail due to ORA-00310, with the behavior also mentioned at DBZ-3377. Using a query mentioned in this issue I've spotted that the online redo logs are about 8 hours old, which roughly matches around the time that the error occurred and the connector stopped. The other three connectors kept on going just fine (even though they are using the same Oracle database, same archive and same redo logs).

      The DBA team advised me to not mine the online redo logs but only the archived ones, since they reuse sequences in the online logs, but I don't see a way of doing that with Debezium. Can you advice me on how to handle this error? Any additional info that is needed?

      I've also seen DBZ-3256, could that be related to this issue?

       

      For reference this is the entire stacktrace that I hit:

      java.sql.SQLException: ORA-00310: archived log contains sequence 692; sequence 689 required
      ORA-00334: archived log: '/zs04/oradata/db1-redo1/db1/onlinelog/o1_mf_11__d5l5qn3l_.log'
      
      	at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:628)
      	at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:562)
      	at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1145)
      	at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:726)
      	at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:291)
      	at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:492)
      	at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:148)
      	at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:1038)
      	at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1097)
      	at oracle.jdbc.driver.OracleStatement.executeSQLSelect(OracleStatement.java:1402)
      	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1285)
      	at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3735)
      	at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3847)
      	at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:1098)
      	at io.debezium.connector.oracle.logminer.LogMinerStreamingChangeEventSource.execute(LogMinerStreamingChangeEventSource.java:184)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.streamEvents(ChangeEventSourceCoordinator.java:140)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.lambda$start$0(ChangeEventSourceCoordinator.java:113)
      	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      	at java.base/java.lang.Thread.run(Thread.java:834)
      

      Attachments

        Activity

          People

            ccranfor@redhat.com Chris Cranford
            jorn.argelo@mn.nl Jorn Argelo (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: