原创:goldengate从11.2升级到12.1.2

goldengate从11.2升级到12.1.2

1.停止抽取进程


GGSCI (001.oracle.drs.dc.com) 286> stop EXTSJ01

2. 停止投递和复制进程

等待投递进程传输完和复制进程加载完毕.当投递进程的Write Checkpoint #1的Sequence和RBA和复制进程的 Current CHECKPOINT的Sequence和RBA相同时表示已同步完毕

2.1检查投递进程:


GGSCI (001.oracle.drs.dc.com) 202> info PUPTDB2P,showch

 

EXTRACT    PUPTDB2P  Last Started 2016-05-04 20:32   Status STOPPED

Checkpoint Lag       00:00:00 (updated 01:12:12 ago)

Log Read Checkpoint  File ./dirdat/exttrdbk/ex000006

                     First Record  RBA 1151

 

 

Current Checkpoint Detail:

 

Read Checkpoint #1

 

  GGS Log Trail

 

  Startup Checkpoint (starting position in the data source):

    Sequence #: 6

    RBA: 1151

    Timestamp: 2016-04-29 14:40:29.589038

    Extract Trail: ./dirdat/exttrdbk/ex

 

  Current Checkpoint (position of last record read in the data source):

    Sequence #: 6

    RBA: 1151

    Timestamp: Not Available

    Extract Trail: ./dirdat/exttrdbk/ex

 

Write Checkpoint #1

 

  GGS Log Trail

 

  Current Checkpoint (current write position):

    Sequence #: 7

    RBA: 1183

    Timestamp: 2016-05-04 20:35:56.803177

    Extract Trail: /home/ggt/goldengate/dirdat/reptdb2p/re

    Trail Type: EXTTRAIL

 

   

2.2检查复制进程  


GGSCI (001.oracle.drs.dc.com) 209> info reptdb2p,showch

 

REPLICAT   REPTDB2P  Last Started 2016-05-04 20:32   Status STOPPED

Checkpoint Lag       00:00:00 (updated 01:14:28 ago)

Log Read Checkpoint  File ./dirdat/reptdb2p/re000007

                     2016-05-04 20:32:43.741679  RBA 1183

 

 

Current Checkpoint Detail:

 

Read Checkpoint #1

 

  GGS Log Trail

 

  Startup Checkpoint (starting position in the data source):

    Sequence #: 6

    RBA: 1246

    Timestamp: 2016-04-29 14:40:29.589110

    Extract Trail: ./dirdat/reptdb2p/re

 

  Current Checkpoint (position of last record read in the data source):

    Sequence #: 7

    RBA: 1183

    Timestamp: 2016-05-04 20:32:43.741679

Extract Trail: ./dirdat/reptdb2p/re

 

2.3停止投递进程和复制进程


GGSCI (001.oracle.drs.dc.com) 209> STOP puptdb2p

GGSCI (001.oracle.drs.dc.com) 210> STOP reptdb2p

 

3.停止管理进程


GGSCI (001.oracle.drs.dc.com) 210> STOP mgr

 

4.备份原来的goldengate


[ggt@001.oracle.drs.dc.com ~]$ mv goldengate goldengate11.2

 

5.安装goldengate 12.1


[ggt@001 ~]$ unzip 121200_fbo_ggs_Linux_x64_shiphome.zip

[ggt@001 ~]$ cd fbo_ggs_Linux_x64_shiphome/Disk1

[ggt@001 ~]$ ./runInstaller

 

选择数据库版本,我的是oracle 11G

 

 

选择安装位置:指定到原始版本的位置;选择是否自动启动管理进程

 

 

 

 

6.检查安装有效性


[ggt@001.oracle.drs.dc.com goldengate]$ ./ggsci

 

Oracle GoldenGate Command Interpreter for Oracle

Version 12.1.2.0.0 17185003 OGGCORE_12.1.2.0.0_PLATFORMS_130924.1316_FBO

Linux, x64, 64bit (optimized), Oracle 11g on Sep 25 2013 00:31:13

Operating system character set identified as UTF-8.

 

Copyright (C) 1995, 2013, Oracle and/or its affiliates. All rights reserved.

 

7.把原版本的相关目录复制到新版本下


[ggt@001 goldengate]$

cp -R /home/ggt/goldengate11.2/dirchk/ .

cp -R /home/ggt/goldengate11.2/dirdat/ .

cp -R /home/ggt/goldengate11.2/dirdef/ .

cp -R /home/ggt/goldengate11.2/dirpcs/ .

cp -R /home/ggt/goldengate11.2/dirprm/ .

cp -R /home/ggt/goldengate11.2/dirrpt/ .

cp -R /home/ggt/goldengate11.2/dirsql/ .

cp -R /home/ggt/goldengate11.2/dirtmp/ .

cp -R /home/ggt/goldengate11.2/BR/ .

 

8.升级复制进程的checkpointtable


GGSCI (001.oracle.drs.dc.com) 20> dblogin userid ggt@mpaysoa_kx, password  pwd

Successfully logged into database.

GGSCI (001.oracle.drs.dc.com) 22> upgrade checkpointtable chk_mpayb2p

 

Successfully upgraded checkpoint table chk_mpayb2p.

 

注意:这一步必须做,否则这报以下错:

2016-05-05 16:31:56  ERROR   OGG-00868  OCI Error ORA-00904: "LOG_BSN": invalid identifier (status = 904). Updating checkpoint table chk_mpay

b2p, group REPMPB2P, key 169,822,320 (0x000000000a1f4870), SQL <UPDATE chk_mpayb2p SET last_update_ts = sysdate, seqno = :seqno, rba = :rba,

audit_ts = :audit_ts, log_bsn = :log_bsn, log_csn = :log_csn, log_xid = :log_xid, log_cmplt_csn = :log_cmplt_csn, log_cmplt_xids = :log_cmplt

_xids, version = :version WHERE group_name = :group_name AND group_key  = :key>.

 

9.启动管理进程


GGSCI (001.oracle.drs.dc.com) 23>start mgr

 

10.启动抽取进程

注意:启动之前,要修改trail文件的格式或把trail的序号向前滚一个序号,否则会报以下错:

ERROR   OGG-01416  File ./dirdat/lt000005, with format RELEASE 11.2, does not match current format specification of RELEASE 12.1. Modify the parameter file to specify format RELEASE 11.2 or issue ETROLLOVER prior to restart.

 

方法一:修改trail文件的格式方法:把开参数文件,在exttrail ./dirdat/sj01/ex后面加上FORMAT RELEASE 11.2


GGSCI (001.oracle.drs.dc.com) 23>edit params extsj01

修改exttrail ./dirdat/sj01/ex为exttrail ./dirdat/sj01/ex, FORMAT RELEASE 11.2

 

方法二:trail的序号向前滚一个序号


GGSCI (001.oracle.drs.dc.com) 262> alter extsj01,etrollover

 

2016-05-05 10:14:51  INFO    OGG-01520  Rollover performed.  For each affected output trail of Version 10 or higher format, after starting the source extract, issue ALTER EXTSEQNO for that trail's reader (either pump EXTRACT or REPLICAT) to move the reader's scan to the new trail file;  it will not happen automatically.

EXTRACT altered.

 

启动抽取进程


GGSCI (001.oracle.drs.dc.com) 262>start extsj01

 

11.启动投递进程

如果在第10步用方法一的话,直接启动投递进程和复制进程就可以了,如果用方法二必须执行以下操作

11.1 记录投递进程的读写检查点


GGSCI (001.oracle.drs.dc.com) 258> info PUPMPBK2,showch

 

EXTRACT    PUPMPBK2  Last Started 2016-05-05 10:01   Status ABENDED

Checkpoint Lag       00:44:46 (updated 00:00:21 ago)

Log Read Checkpoint  File /home/ggt/goldengate/dirdat/sj01/ex194468

                     2016-05-05 09:16:27.000000  RBA 2244115

 

 

Current Checkpoint Detail:

 

Read Checkpoint #1

 

  GGS Log Trail

 

  Startup Checkpoint (starting position in the data source):

    Sequence #: 194468

    RBA: 2244115

    Timestamp: 2016-05-05 09:16:27.000000

    Extract Trail: /home/ggt/goldengate/dirdat/sj01/ex

 

  Current Checkpoint (position of last record read in the data source):

    Sequence #: 194468

    RBA: 2244115

    Timestamp: 2016-05-05 09:16:27.000000

    Extract Trail: /home/ggt/goldengate/dirdat/sj01/ex

 

Write Checkpoint #1

 

  GGS Log Trail

 

  Current Checkpoint (current write position):

    Sequence #: 6184

    RBA: 36936583

    Timestamp: 2016-05-05 09:16:30.784940

    Extract Trail: /home/ggt/goldengate/dirdat/repmpaybak/re

    Trail Type: RMTTRAIL

 

Header:

  Version = 2

  Record Source = A

  Type = 1

  # Input Checkpoints = 1

  # Output Checkpoints = 1

 

File Information:

  Block Size = 2048

  Max Blocks = 100

  Record Length = 2048

  Current Offset = 0

 

Configuration:

  Data Source = 0

  Transaction Integrity = 1

  Task Type = 0

 

Status:

  Start Time = 2016-05-05 10:01:08

  Last Update Time = 2016-05-05 10:01:13

  Stop Status = A

  Last Result = 0

 

11.2 修改Read Checkpoint和Write Checkpoint


GGSCI (001.oracle.drs.dc.com) 262> alter PUPMPBK2,etrollover

 

2016-05-05 10:14:51  INFO    OGG-01520  Rollover performed.  For each affected output trail of Version 10 or higher format, after starting the source extract, issue ALTER EXTSEQNO for that trail's reader (either pump EXTRACT or REPLICAT) to move the reader's scan to the new trail file;  it will not happen automatically.

EXTRACT altered.

 

GGSCI (001.oracle.drs.dc.com) 262>   alter PUPMPBK2,extseqno 194469 extrba 0

注意:extseqno 194469是在Read Checkpoint的Sequence #: 194468加1,因为在抽取进程上用etrollover向前滚了一个序号

 

GGSCI (001.oracle.drs.dc.com) 262>start PUPMPBK2

11.3启动投递进程


GGSCI (001.oracle.drs.dc.com) 262>start PUPMPBK2

 

12. 启动复制进程

12.1查看复制进程的加载位置


GGSCI (001.oracle.drs.dc.com) 21> info REPMPB2P,showch

 

REPLICAT   REPMPB2P  Last Started 2016-05-05 16:31   Status ABENDED

Checkpoint Lag       00:00:00 (updated 00:04:42 ago)

Log Read Checkpoint  File ./dirdat/repmpb2p/re000083

                     First Record  RBA 0

 

 

Current Checkpoint Detail:

 

Read Checkpoint #1

 

  GGS Log Trail

 

  Startup Checkpoint (starting position in the data source):

   Sequence #: 6184

    RBA: 36936583

    Timestamp: Not Available

    Extract Trail: ./dirdat/repmpb2p/re

 

  Current Checkpoint (position of last record read in the data source):

   Sequence #: 6184

    RBA: 36936583

    Timestamp: Not Available

    Extract Trail: ./dirdat/repmpb2p/re

12.2修改复制进程的Sequence #和RBA


GGSCI (001.oracle.drs.dc.com) 22>alter REPMPB2P extseqno 6185 extrba 0

注意:extseqno 6185是在Current Checkpoint的Sequence #: 6184加1,因为在投递进程上用etrollover向前滚了一个序号

 

 

12.3 启动复制进程


GGSCI (001.oracle.drs.dc.com) 22>start REPMPB2P

 

13 升级完成

恭喜你,至此你已成功完成goldengate的11g到12c的升级

时间: 2024-09-20 13:57:08

原创:goldengate从11.2升级到12.1.2的相关文章

探索Oracle之数据库升级九 12.1.0.1 Update 12.1.0.2

探索Oracle之数据库升级九 12.1.0.1 Update 12.1.0.2 一.检查当前数据库版本及系统信息 [oracle@db01 ~]$ lsb_release -a LSB Version: :core-4.0-amd64:core-4.0-ia32:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-ia32:printin

还可以这么玩:盘点iOS 11中Siri的12项新功能

本文讲的是还可以这么玩:盘点iOS 11中Siri的12项新功能,iOS 11的首次亮相带来了一些变化,其中包括增强现实游戏和更好的iMessage体验,但或许操作系统在任何方面的改变都不如Siri大. Siri有了更多的新性能,通过分享社交账号QR码得到更生动的形象,以及它可以演奏DJ. 以下是对iOS 11中Siri的所有操作方式的总结: 1.跨设备同步 通过iOS 11系统,Siri可以总结并适应你的习惯,并在你所有的苹果设备上同步这些偏好. 比如在你的联系人列表里有四个人叫Brianna

天涯共此双11——天猫升级港澳台“购物天堂”

香港北区上水60多年的老字号正和隆酱油没想过会出名.这家专注服务街坊的小店不在乎"酱香巷子深",门店一半是透明及地的塑胶门帘,一半是一块块拼接起来的黄色纸板箱. 来的都是熟客,所谓收银台就是个铅桶,顾客要付钱就把铅桶拉下来,付钱.找零,再把铅桶放上去. 这是父辈们持续了半个多世纪的生意.到了店主女儿这里,事情开始改变.她赶时髦,在店里放了有支付宝二维码的蓝白色纸板."好麻烦."父亲抱怨. 但他没想到,就是这一个二维码,从此让小店的生意溢出固守60年的街区.由于在支付

客户快递11箱白酒破损12瓶圆通未给赔偿办法

17日,读者易先生向本报投诉称,他委托圆通速递南昌市红谷滩分部运送11箱贵重白酒至广东省普宁市,结果破损了12瓶,圆通速递公司相关负责人对此没有给他一个满意答复. 易先生告诉记者,1月7日左右,他委托圆通速递南昌市红谷滩分部运送11箱贵重白酒到广东省普宁市,5天后他得知8箱白酒运到当地后少了1瓶,破损4瓶,剩余3箱白酒,还在南昌便破损了7瓶.双方协商达不成一致. 17日上午,记者就此事采访圆通速递南昌市红谷滩分部负责人唐某时,唐某表示不接受采访,只和客户易先生的妻子张女士协商.约15分钟后,张女

百度凤巢11月升级内幕 你知多少

中介交易 http://www.aliyun.com/zixun/aggregation/6858.html">SEO诊断 淘宝客 云主机 技术大厅 百度凤巢即将再一次进行升级,升级后它对我们产生怎样影响呢?我们又将如何应对此次的升级呢?以下为本人在百度推广中的一些问题结合与百度推广客户电话通话后的总结. 本网站百度推广现状 1 点击量低 2 展现量大 3 30%质量度为一星 4 点击率过低(不足1%) 升级后的三大调整 1 质量度将重新计算 升级后质量度计算主要以账户的历史表现,关键词的

Mac OS10.11下mysql5.7.12 安装配置方法图文教程

Mac OS10.11安装和配置MySQL,主要是图,步骤我简单说明一下. 首先访问mysql官网并下载安装程序,当然在下载之前你需要线注册下账号. 网站地址:MySQL下载页面,下载两个安装程序:MySQL Community Server.MySQL Workbench. MySQL Community Server 点击进入下载页面,在页面最下方,有下载选项,请确认选择的平台是Mac OS X,然后下载下图用红框划出的安装包.下载时需要登录帐号. 下载后运行,直接运行mysql.pkg,在

11·11才败过12·12又大促电商造节上瘾了!

错过了"双11",那么这个"双12"就不容错过了.没错,电商们又在蛊惑你掏钱为一个接一个的http://www.aliyun.com/zixun/aggregation/7676.html">网络购物节买单了.尽管有的市民在光棍节狂购的宝贝上周末才到货,但这并不妨碍磨刀霍霍的电商们为还有一周便要到来的"双12"积极备战. 本期深阅读 探营双12节 市民王斌在10月底购买了新车,在电商双11大战中购买了一堆汽车用品,这些商品上周末才

电商行业在双11促销战升级到流量争夺暗战

电商行业在"双11"促销战上的竞争已从拼价格.物流升级到流量争夺暗战.当当已斥资百万元购得"shuang11.com"域名,并将其打造为电商分享导购网站,直接截流"双11"用户. 消息称,在"双11"前夕, 当当网 重金购得"shuang11.com"域名,将其运营为"'双11'购物导航"网站,目前已正式上线.北京商报记者登录该网站发现,其定位于精品导航网站,主要分为"达人推荐

oracle中升级到12.1.0.2之后rman无法删除已经归档日志

客户一个数据库,架构是2地3中心,本地有primary和standby,远程还有一个standby. primary的rman archivelog deletion policy是ship to all standby 同城standby的rman archivelog deletion policy是backup 1 time,备份在同城standby上进行. 远程standby的rman archivelog deletion policy是applied on all standby.