暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

OGG报错 In recovery[1]: Processing data with empty data queue 问题处理

OGG报错 In recovery[1]: Processing data with empty data queue 问题处理

故障情况

-- 1 应用反馈没有数据同步,检查时延时24小时以上,进程状态一直是In recovery[1]
-- 2 停抽取进程停不下来,使用send extract E_1,forcestop也不管用
-- 3 从操作系统杀掉抽取进程,重新之后ggserr.log报缺归档,OGG读归档时,归档文件被force delete
-- 4 从备份恢复归档之后,重启进程状态还是In recovery[1],
-- 5 等了4个小时以上等抽取进程状态恢复,状态还是不变,检查进程状态,读的归档位置没有没有变化
-- 6 考虑到OGG进程不能恢复,由于归档空间有限,删掉重建抽取进程,只能从报最后一次读归档位置的时间开始重新抽取
-- 7 重建抽取进程之后,ggserr.log报初始化还需要指定时间之后的两个归档,补上归档之后开始抽取

1 查看进程状态

很长一段时间(超过12小时)一直是In recovery[1] info EXTRACT E_1 detail send EXTRACT E_1,status send EXTRACT E_1,showtrans SEND EXTRACT E_1,FORCESTOP info extract E_1,showch Current status: In recovery[1]: Processing data with empty data queue Current read positions: Redo thread #: 1 Sequence #: 922554 RBA: 674368 Timestamp: 2021-08-19 18:38:09.000000 SCN: 4103.2602569671 (17624853385159) Redo thread #: 2 Sequence #: 959781 RBA: 1375787164 Timestamp: 2021-08-19 18:35:46.000000 SCN: 4103.2600614591 (17624851430079) Current write position: Sequence #: 1140267 RBA: 1578 Timestamp: 2021-08-20 20:26:47.104235 Extract Trail: ./dirdat/x1

2 删掉抽取进程

dblogin userid ...... stop extract E_1 ps -ef | grep E_1 kill -9 pid 进程停不掉,从操作系统杀进程 delete extract E_1

3 停掉投递进程

投递进程停不掉也可以从操作系统杀进程 stop extract P1

4 备份当前的队列文件之后清理

-- rm x1* -f -- 可以在这期间模拟DML -- DML

5 重建抽取进程

注意进程名称不能变,不能unregister 抽取进行,使用原来的经典模式 add extract E_1,tranlog,threads 2,begin now add exttrail ./dirdat/x1,extract E_1,MEGABYTES 500

6 从指定时间开始抽取,启动进程

alter extract E_1,begin 2021-08-19 18:35:46 start extract E_1

7 修改投递进程

-- 从新的0号队列文件开始投递,并切换远端的队列文件 info E_1 detail alter extract P1,EXTSEQNO 0,EXTRBA 0 alter extract P1,ETROLLOVER start P1

8 启动应用进程

-- 注意,由于是另起进程抽取投递的,原应用进程可能不会自动切换队列文件应用,需要手动切一下应用进程,从新的队列文件开始应用 stop r1 alter REPLICAT r1,EXTSEQNO 7,EXTRBA 0 start r1

附:恢复归档过程

-- 检查OGG需要的被删除的归档 select thread#,sequence#,DELETED from v$archived_log where DEST_ID=1 and sequence#>959781 and DELETED='YES' and thread#=2 order by 2; select thread#,sequence#,DELETED from v$archived_log where DEST_ID=1 and sequence#>922554 and DELETED='YES' and thread#=1 order by 2; -- 从ADG恢复归档到主库 -- 先要执行命令扫描NBU备份 /usr/openv/netbackup/bin/bplist -S 'master' -C 'db3' -t 4 -R / | more RUN { ALLOCATE CHANNEL c0 TYPE 'SBT_TAPE' ; ALLOCATE CHANNEL c1 TYPE 'SBT_TAPE' ; SEND 'NB_ORA_SERV=master,NB_ORA_CLIENT=db3'; set archivelog destination to '+FRA'; # restore archivelog logseq 959781 thread 2; # restore archivelog from logseq 959781 thread 2; restore archivelog from logseq 959781 until logseq 959896 thread 2; release CHANNEL c0; release CHANNEL c1; } list archivelog sequence between 959781 and 959896; -- 从备库cp归档到主库 asmcmd cp --port 1522 +FRA/orcladg/archivelog/2021_08_19/thread_2_seq_959781.1104.1080970581 sys/password@10.115.152.21.+ASM1:+FRA/RBCK/thread_2_seq_959781 -- 在主库重新注册归档 catalog start with '+FRA/RBCK/' noprompt;
「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论