You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by "Quilian (via GitHub)" <gi...@apache.org> on 2025/02/20 07:19:17 UTC

[I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Quilian opened a new issue, #8772:
URL: https://github.com/apache/seatunnel/issues/8772

   ### Search before asking
   
   - [x] I had searched in the [issues](https://github.com/apache/seatunnel/issues?q=is%3Aissue+label%3A%22bug%22) and found no similar issues.
   
   
   ### What happened
   
   Oracle-cdc任务运行一个月发生报错,报错:Caused by: java.sql.SQLException: ORA-00310: archived log contains sequence 14319; sequence 14316 requiredORA-00334: archived log: '/OSdata/oradata_ncdb/SJZTNCDB/redo03.log'。但是检查数据库保存点是连续正常的:
   -rw-r----- 1 oracle oinstall 202161688 Feb 19 10:23 o1_mf_14313_mvbht21b_.arc
   -rw-r----- 1 oracle oinstall 109754880 Feb 19 10:23 o1_mf_14314_mvb5wy6_.arc
   -rw-r----- 1 oracle oinstall  53207744 Feb 19 10:23 o1_mf_14315_mvb57yh_.arc
   -rw-r----- 1 oracle oinstall 196684888 Feb 19 10:24 o1_mf_14316_mvb6r7x_.arc
   -rw-r----- 1 oracle oinstall 195910144 Feb 19 10:24 o1_mf_14317_mvb6j6t_.arc
   -rw-r----- 1 oracle oinstall 195910144 Feb 19 10:24 o1_mf_14318_mvb6jtw_.arc
   -rw-r----- 1 oracle oinstall 195910144 Feb 19 10:24 o1_mf_14319_mvb6vxm_.arc
   -rw-r----- 1 oracle oinstall 196322528 Feb 19 10:24 o1_mf_14320_mvb6y1h_.arc
   -rw-r----- 1 oracle oinstall 198780288 Feb 19 10:24 o1_mf_14322_mvb74vy_.arc
   -rw-r----- 1 oracle oinstall 201594728 Feb 19 10:25 o1_mf_14324_mvb8y0t_.arc
   -rw-r----- 1 oracle oinstall  93376824 Feb 19 10:35 o1_mf_14327_mvbvsyf_.arc
   
   ### SeaTunnel Version
   
   2.3.9
   
   ### SeaTunnel Config
   
   ```conf
   env{
     execution.parallelism = 1
     job.mode = "STREAMING"
     checkpoint.interval =1000
   }
   source {
     Oracle-CDC {
         username = "xx"
         password = "xxx"
         database-names = ["db1"]
         schema-names = ["sc1"]
         table-names = ["db1.sc1.table1"]
         connect.timeout.ms = 60000
         connect.max-retries = 5
         base-url = "jdbc:oracle:thin:@xx.xxx.xxx.xx:xxxx:db1"
       }
   }
   sink {
     Doris {
         fenodes = "xx.xxx.xx.xxx:xxxx"
         username = xxx
         password = "xxxxx"
         database = "xxx"
         #table = "xxxx"
         sink.enable-2pc = "false"
         sink.label-prefix = "xxx_111"
         sink.enable-delete = "true"
         doris.config = {
               format="json"
               read_json_by_line="true"
           }
       }
   }
   ```
   
   ### Running Command
   
   ```shell
   bin/seatunnel.sh -c cdc.template --async
   ```
   
   ### Error Exception
   
   ```log
   2025-02-19 10:29:10,909 ERROR [o.a.s.e.s.d.p.PhysicalVertex  ] [hz.main.generic-operation.thread-5] - Job db_oracle_cdc (933615545725485057), Pipeline: [(1/1)], task: [pipeline-1 [Source[0]-Oracle-CDC]-SourceTask (1/1)] end with state FAILED and Exception: java.lang.RuntimeException: One or more fetchers have encountered exception
           at org.apache.seatunnel.connectors.seatunnel.common.source.reader.fetcher.SplitFetcherManager.checkErrors(SplitFetcherManager.java:147)
           at org.apache.seatunnel.connectors.seatunnel.common.source.reader.SourceReaderBase.getNextFetch(SourceReaderBase.java:167)
           at org.apache.seatunnel.connectors.seatunnel.common.source.reader.SourceReaderBase.pollNext(SourceReaderBase.java:93)
           at org.apache.seatunnel.connectors.cdc.base.source.reader.IncrementalSourceReader.pollNext(IncrementalSourceReader.java:119)
           at org.apache.seatunnel.engine.server.task.flow.SourceFlowLifeCycle.collect(SourceFlowLifeCycle.java:159)
           at org.apache.seatunnel.engine.server.task.SourceSeaTunnelTask.collect(SourceSeaTunnelTask.java:127)
           at org.apache.seatunnel.engine.server.task.SeaTunnelTask.stateProcess(SeaTunnelTask.java:169)
           at org.apache.seatunnel.engine.server.task.SourceSeaTunnelTask.call(SourceSeaTunnelTask.java:132)
           at org.apache.seatunnel.engine.server.TaskExecutionService$BlockingWorker.run(TaskExecutionService.java:694)
           at org.apache.seatunnel.engine.server.TaskExecutionService$NamedTaskWrapper.run(TaskExecutionService.java:1019)
           at org.apache.seatunnel.api.tracing.MDCRunnable.run(MDCRunnable.java:43)
           at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
           at java.util.concurrent.FutureTask.run(FutureTask.java:266)
           at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
           at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
           at java.lang.Thread.run(Thread.java:750)
   Caused by: java.lang.RuntimeException: SplitFetcher thread 0 received unexpected exception while polling the records
           at org.apache.seatunnel.connectors.seatunnel.common.source.reader.fetcher.SplitFetcher.runOnce(SplitFetcher.java:165)
           at org.apache.seatunnel.connectors.seatunnel.common.source.reader.fetcher.SplitFetcher.run(SplitFetcher.java:81)
           ... 5 more
   Caused by: org.apache.kafka.connect.errors.ConnectException: An exception occurred in the change event producer. This connector will be stopped.
           at io.debezium.pipeline.ErrorHandler.setProducerThrowable(ErrorHandler.java:50)
           at io.debezium.connector.oracle.logminer.LogMinerStreamingChangeEventSource.execute(LogMinerStreamingChangeEventSource.java:264)
           at org.apache.seatunnel.connectors.seatunnel.cdc.oracle.source.reader.fetch.logminer.OracleRedoLogFetchTask$RedoLogSplitReadTask.execute(OracleRedoLogFetchTask.java:147)
           at org.apache.seatunnel.connectors.seatunnel.cdc.oracle.source.reader.fetch.logminer.OracleRedoLogFetchTask.execute(OracleRedoLogFetchTask.java:73)
           at org.apache.seatunnel.connectors.cdc.base.source.reader.external.IncrementalSourceStreamFetcher.lambda$submitTask$0(IncrementalSourceStreamFetcher.java:107)
           ... 5 more
   Caused by: java.sql.SQLException: ORA-00310: archived log contains sequence 14319; sequence 14316 required
   ORA-00334: archived log: '/OSdata/oradata_ncdb/SJZTNCDB/redo03.log'
   
           at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:494)
           at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:446)
           at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1054)
           at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:623)
           at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:252)
           at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:612)
           at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:226)
           at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:59)
           at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:747)
           at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:904)
           at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1082)
           at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3780)
           at oracle.jdbc.driver.T4CPreparedStatement.executeInternal(T4CPreparedStatement.java:1343)
           at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3822)
           at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:1165)
           at io.debezium.connector.oracle.logminer.processor.AbstractLogMinerEventProcessor.process(AbstractLogMinerEventProcessor.java:185)
           at io.debezium.connector.oracle.logminer.LogMinerStreamingChangeEventSource.execute(LogMinerStreamingChangeEventSource.java:252)
           ... 8 more
   Caused by: Error : 310, Position : 0, Sql = SELECT SCN, SQL_REDO, OPERATION_CODE, TIMESTAMP, XID, CSF, TABLE_NAME, SEG_OWNER, OPERATION, USERNAME, ROW_ID, ROLLBACK, RS_ID, STATUS, INFO, SSN, THREAD# FROM V$LOGMNR_CONTENTS WHERE SCN > :1  AND SCN <= :2  AND (SEG_OWNER IS NULL OR SEG_OWNER NOT IN ('APPQOSSYS','AUDSYS','CTXSYS','DVSYS','DBSFWUSER','DBSNMP','GSMADMIN_INTERNAL','LBACSYS','MDSYS','OJVMSYS','OLAPSYS','ORDDATA','ORDSYS','OUTLN','SYS','SYSTEM','WMSYS','XDB')) AND ((OPERATION_CODE IN (6,7,34,36) OR (OPERATION_CODE = 5 AND USERNAME NOT IN ('SYS','SYSTEM') AND INFO NOT LIKE 'INTERNAL DDL%' AND (TABLE_NAME IS NULL OR TABLE_NAME NOT LIKE 'ORA_TEMP_%')) ) OR (OPERATION_CODE IN (1,2,3,255) AND TABLE_NAME != 'LOG_MINING_FLUSH' AND (REGEXP_LIKE(SEG_OWNER,'^DBO_AODB$','i')) AND (REGEXP_LIKE(SEG_OWNER || '.' || TABLE_NAME,'^DBO_AODB.PLANFLIGHT$','i')) )), OriginalSql = SELECT SCN, SQL_REDO, OPERATION_CODE, TIMESTAMP, XID, CSF, TABLE_NAME, SEG_OWNER, OPERATION, USERNAME, ROW_ID, ROLLB
 ACK, RS_ID, STATUS, INFO, SSN, THREAD# FROM V$LOGMNR_CONTENTS WHERE SCN > ? AND SCN <= ? AND (SEG_OWNER IS NULL OR SEG_OWNER NOT IN ('APPQOSSYS','AUDSYS','CTXSYS','DVSYS','DBSFWUSER','DBSNMP','GSMADMIN_INTERNAL','LBACSYS','MDSYS','OJVMSYS','OLAPSYS','ORDDATA','ORDSYS','OUTLN','SYS','SYSTEM','WMSYS','XDB')) AND ((OPERATION_CODE IN (6,7,34,36) OR (OPERATION_CODE = 5 AND USERNAME NOT IN ('SYS','SYSTEM') AND INFO NOT LIKE 'INTERNAL DDL%' AND (TABLE_NAME IS NULL OR TABLE_NAME NOT LIKE 'ORA_TEMP_%')) ) OR (OPERATION_CODE IN (1,2,3,255) AND TABLE_NAME != 'LOG_MINING_FLUSH' AND (REGEXP_LIKE(SEG_OWNER,'^DBO_AODB$','i')) AND (REGEXP_LIKE(SEG_OWNER || '.' || TABLE_NAME,'^DBO_AODB.PLANFLIGHT$','i')) )), Error Msg = ORA-00310: archived log contains sequence 14319; sequence 14316 required
   ORA-00334: archived log: '/OSdata/oradata_ncdb/SJZTNCDB/redo03.log'
   
           at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:498)
           ... 24 more
   ```
   
   ### Zeta or Flink or Spark Version
   
   zeta
   
   ### Java or Scala Version
   
   _No response_
   
   ### Screenshots
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [x] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #8772: [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。
URL: https://github.com/apache/seatunnel/issues/8772


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "kingxeros (via GitHub)" <gi...@apache.org>.
kingxeros commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-2899931362

   Has this bug been fixed?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "kingxeros (via GitHub)" <gi...@apache.org>.
kingxeros commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-2771533118

   Can anyone help? Is this issue a bug ? thanks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "nero520 (via GitHub)" <gi...@apache.org>.
nero520 commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-3384734929

   > I need help. The same thing has been sent twice. The second time, it was possible to restore using the checkpoint, which indicates that the database log is not broken.
   
   请问解决了吗?我也遇到同类问题


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "kingxeros (via GitHub)" <gi...@apache.org>.
kingxeros commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-2756770101

   I met the same problem. This problem happens irregularly


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "yinshile (via GitHub)" <gi...@apache.org>.
yinshile commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-2781868308

   这个我遇到过,是因为oracle-cdc同步数据会越来越慢,比如第10天其实只同步了前8天的数据,第20天只同步到前15天的数据,第30天只同步了22天的数据,如果归档日志保存时间只有7天,那在第30天的时候,快照那边保存的是第22天的归档日志sequence位置,这时去同步前8天的日志,这时就会报对应的sequence位置找不到


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "Quilian (via GitHub)" <gi...@apache.org>.
Quilian commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-2723100665

   I need help. The same thing has been sent twice. The second time, it was possible to restore using the checkpoint, which indicates that the database log is not broken. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-3064419548

   This issue has been automatically marked as stale because it has not had recent activity for 30 days. It will be closed in next 7 days if no further activity occurs.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [Oracle-CDC] 报错Oracle日志保存点断裂,但是数据库日志查看正常,未发生断裂。 [seatunnel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #8772:
URL: https://github.com/apache/seatunnel/issues/8772#issuecomment-3092661051

   This issue has been closed because it has not received response for too long time. You could reopen it if you encountered similar problems in the future.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org