oracle goldengate报错解决之OGG-00446、OGG-00529、OGG-00014

前端之家收集整理的这篇文章主要介绍了oracle goldengate报错解决之OGG-00446、OGG-00529、OGG-00014前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

OGG测试:无法启动ext进程,报错OGG-00446


报错日志【截取重要部分】

2016-10-2816:51:40ERROROGG-00446Missingfilenameopeningcheckpointfile.
2016-10-2816:51:40ERROROGG-01668PROCESSABENDING.

日志意思很明显:在打开checkpoint file 时缺少文件

查看参数:

oracle@a-test30dirprm]$moreext1.prm
UserIdogg,Passwordogg
ExtTrail./dirdat/eo
GetTruncates
TranlogoptionsExcludeUserogg
--DDLIncludeAll
DDL&
INCLUDEMAPPEDOBJTYPE'table'&
INCLUDEMAPPEDOBJTYPE'index'&
EXCLUDEOPTYPECOMMENT
DDLOptionsAddTranDataRetryopRetrydelay10Maxretries10
TableTMP.test1;
TableTMP.test2;
TableTMP.test3
[oracle@a-test30dirprm]$morepump1.prm
Extractpump1
PassThru
RmtHost192.168.10.61,MgrPort7809
RmtTrail./dirdat/go

TableTMP.test1;
TableTMP.test2;
TableTMP.test3;

发现ext1.prm没有文件头名

加上Extract ext1

GGSCI(a-test30asogg@qatest30)27>viewparamsext1
Extractext1
UserIdogg,Passwordogg
ExtTrail./dirdat/eo
GetTruncates
TranlogoptionsExcludeUserogg
--DDLIncludeAll
DDL&
INCLUDEMAPPEDOBJTYPE'table'&
INCLUDEMAPPEDOBJTYPE'index'&
EXCLUDEOPTYPECOMMENT
DDLOptionsAddTranDataRetryopRetrydelay10Maxretries10
TableTMP.test1;
TableTMP.test2;
TableTMP.test3;

再去启动又继续报错OGG-00529

016-10-2817:02:15ERROROGG-00529DDLReplicationisenabledbuttablegoldengate.GGS_DDL_HISTisnotfound.PleasecheckDDLinstallationinthedatabase.
2016-10-2817:02:15ERROROGG-01668PROCESSABENDING.

分析:
查阅各种资料分析可能原因

根据日志可以看出DDL复制操作已经打开,但没有找到安装复制DDL执行脚本产生的表GGS.GGS_DDL_HIST导致的故障,会不会是因为安装复制DDL是使用用户ogg,执行脚本后会在该用户产生跟踪goldengate运行的表,所以要实现支持DDL操作,在参数文件登录数据库必须使用GGDLL和对应的密码登录

【针对rac多节点:USERID ogg@qatest30,PASSWORD ogg】

实际原因:

原因是配置源端mgr参数文件时用的是用户名和密码是ogg,且配置支持DDL复制时输入的用户名也是ogg。但目标端mgr参数文件中配置的用户名密码是goldengate,源端目标端不匹配,找不到验证信息。


解决方法

卸载ogg,并使支持DDL功能失效

运行脚本即可

注意:一定要在ogg软件安装目录下登陆数据库,运行脚本,否则是打不开文件的~~

sql>@ddl_disable.sql
SP2-0310:无法打开文件"ddl_disable.sql"
[oracle@a-test30softogg1]$!sql
sqlplus/assysdba
sql*Plus:Release11.2.0.1.0Productionon星期二11月111:35:042016
Copyright(c)1982,2009,Oracle.Allrightsreserved.
连接到:
OracleDatabase11gEnterpriseEditionRelease11.2.0.1.0-64bitProduction
WiththePartitioning,OLAP,DataMiningandRealApplicationTestingoptions
sql>@ddl_disable.sql
触发器已更改
sql>@ddl_remove.sql
DDLreplicationremovalscript.
WARNING:thisscriptremovesallDDLreplicationobjectsanddata.
YouwillbepromptedforthenameofaschemafortheOracleGoldenGatedatabaSEObjects.
NOTE:Theschemamustbecreatedpriortorunningthisscript.
EnterOracleGoldenGateschemaname:ogg
Working,pleasewait...
Spoolingtofileddl_remove_spool.txt
Scriptcomplete.
sql>
sql>@marker_remove.sql
Markerremovalscript.
WARNING:thisscriptremovesallmarkerobjectsanddata.
YouwillbepromptedforthenameofaschemafortheOracleGoldenGatedatabaSEObjects.
NOTE:Theschemamustbecreatedpriortorunningthisscript.
EnterOracleGoldenGateschemaname:ogg
PL/sql过程已成功完成。
序列已删除。
表已删除。

Scriptcomplete.

重新安装:

[oracle@a-test30softogg1]$!sql
sqlplus/assysdba
sql*Plus:Release11.2.0.1.0Productionon星期二11月114:44:532016
Copyright(c)1982,DataMiningandRealApplicationTestingoptions
sql>@marker_setup.sql
Markersetupscript
YouwillbepromptedforthenameofaschemafortheOracleGoldenGatedatabaSEObjects.
NOTE:Theschemamustbecreatedpriortorunningthisscript.
NOTE:StopallDDLreplicationbeforestartingthisinstallation.
EnterOracleGoldenGateschemaname:goldengate
Markersetuptablescriptcomplete,runningverificationscript...
PleaseenterthenameofaschemafortheGoldenGatedatabaSEObjects:
SettingschemanametoGOLDENGATE
MARKERTABLE
-------------------------------
OK
MARKERSEQUENCE
-------------------------------
OK
Scriptcomplete.
sql>@ddl_setup.sql
OracleGoldenGateDDLReplicationsetupscript
VerifyingthatcurrentuserhasprivilegestoinstallDDLReplication...
YouwillbepromptedforthenameofaschemafortheOracleGoldenGatedatabaSEObjects.
NOTE:ForanOracle10gsource,thesystemrecyclebinmustbedisabled.ForOracle11gandlater,itcanbeenabled.
NOTE:Theschemamustbecreatedpriortorunningthisscript.
NOTE:StopallDDLreplicationbeforestartingthisinstallation.
EnterOracleGoldenGateschemaname:goldengate
Working,pleasewait...
Spoolingtofileddl_setup_spool.txt
CheckingforsessionsthatareholdinglocksonOracleGoldenGateMetadatatables...
Checkcomplete.
WARNING:TablespaceOGGdoesnothaveAUTOEXTENDenabled.
declare
*
第1行出现错误:
ORA-20783:
ORA-20783:
OracleGoldenGateDDLReplicationsetup:
***PleasemoveGOLDENGATEtoitsowntablespace
ORA-06512:在line34
从OracleDatabase11gEnterpriseEditionRelease11.2.0.1.0-64bitProduction
WiththePartitioning,DataMiningandRealApplicationTestingoptions断开
报错说需要将goldengate迁移到自己的表空间上
改就是了:
[oracle@a-test30softogg1]$sqlplus/assysdba
sql*Plus:Release11.2.0.1.0Productionon星期二11月115:57:122016
Copyright(c)1982,DataMiningandRealApplicationTestingoptions
sql>
sql>createtablespacegoldengatedatafile'/oradata01/qatest30/goldengate_data_01.dbf'size30gautoextendoff;
表空间已创建。
sql>alteruseroggdefaulttablespacegoldengate;
用户已更改。
sql>@ddl_setup.sql
OracleGoldenGateDDLReplicationsetupscript
VerifyingthatcurrentuserhasprivilegestoinstallDDLReplication...
YouwillbepromptedforthenameofaschemafortheOracleGoldenGatedatabaSEObjects.
NOTE:ForanOracle10gsource,pleasewait...
Spoolingtofileddl_setup_spool.txt
CheckingforsessionsthatareholdinglocksonOracleGoldenGateMetadatatables...
Checkcomplete.
WARNING:TablespaceOGGdoesnothaveAUTOEXTENDenabled.
UsingGOLDENGATEasaOracleGoldenGateschemaname.
Working,pleasewait...
DDLreplicationsetupscriptcomplete,runningverificationscript...
PleaseenterthenameofaschemafortheGoldenGatedatabaSEObjects:
SettingschemanametoGOLDENGATE
CLEAR_TRACESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
CREATE_TRACESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
TRACE_PUT_LINESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
INITIAL_SETUPSTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLVERSIONSPECIFICPACKAGESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLREPLICATIONPACKAGESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLREPLICATIONPACKAGEBODYSTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLIGNORETABLE
-----------------------------------
OK
DDLIGNORELOGTABLE
-----------------------------------
OK
DDLAUXPACKAGESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLAUXPACKAGEBODYSTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
SYS.DDLCTXINFOPACKAGESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
SYS.DDLCTXINFOPACKAGEBODYSTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLHISTORYTABLE
-----------------------------------
OK
DDLHISTORYTABLE(1)
-----------------------------------
OK
DDLDUMPTABLES
-----------------------------------
OK
DDLDUMPCOLUMNS
-----------------------------------
OK
DDLDUMPLOGGROUPS
-----------------------------------
OK
DDLDUMPPARTITIONS
-----------------------------------
OK
DDLDUMPPRIMARYKEYS
-----------------------------------
OK
DDLSEQUENCE
-----------------------------------
OK
GGS_TEMP_COLS
-----------------------------------
OK
GGS_TEMP_UK
-----------------------------------
OK
DDLTRIGGERCODESTATUS:
Line/posError
-------------------------------------------------------------------------------------
NoerrorsNoerrors
DDLTRIGGERINSTALLSTATUS
-----------------------------------
OK
DDLTRIGGERRUNNINGSTATUS
----------------------------------------------------------------------
ENABLED
STAYMetaDATAINTRIGGER
----------------------------------------------------------------------
OFF
DDLTRIGGERsqlTRACING
----------------------------------------------------------------------
0
DDLTRIGGERTRACELEVEL
----------------------------------------------------------------------
0
LOCATIONOFDDLTRACEFILE
------------------------------------------------------------------------------------------------------------------------
/oracle/diag/rdbms/qatest30/qatest30/trace/ggs_ddl_trace.log
Analyzinginstallationstatus...
VERSIONOFDDLREPLICATION
------------------------------------------------------------------------------------------------------------------------
OGGCORE_12.1.2.1.0_PLATFORMS_140727.2135.1
STATUSOFDDLREPLICATION
------------------------------------------------------------------------------------------------------------------------
SUCCESSFULinstallationofDDLReplicationsoftwarecomponents
Scriptcomplete.
sql>
sql>@role_setup.sql
GGSRolesetupscript
ThisscriptwilldropandrecreatetheroleGGS_GGSUSER_ROLE
Touseadifferentrolename,quitthisscriptandthenedittheparams.sqlscripttochangethegg_roleparametertothepreferredname.(Donotrunthescript.)
YouwillbepromptedforthenameofaschemafortheGoldenGatedatabaSEObjects.
NOTE:Theschemamustbecreatedpriortorunningthisscript.
NOTE:StopallDDLreplicationbeforestartingthisinstallation.
EnterGoldenGateschemaname:goldengate
已写入filerole_setup_set.txt
PL/sql过程已成功完成。
Rolesetupscriptcomplete
GrantthisroletoeachuserassignedtotheExtract,GGSCI,andManagerprocesses,byusingthefollowingsqlcommand:
GRANTGGS_GGSUSER_ROLETO<loggedUser>
where<loggedUser>istheuserassignedtotheGoldenGateprocesses.
sql>GRANTGGS_GGSUSER_ROLEtogoldengate;
授权成功。
sql>@ddl_enable.sql
触发器已更改

可以了,再去启动,报错OGG-00014

2016-11-0117:26:46ERROROGG-00014Unrecognizedparameter:chema.Parametercouldbemisspelledorunsupported.
2016-11-0117:26:46ERROROGG-01668PROCESSABENDING.
2016-11-0117:26:46WARNINGOGG-00543Unexpectedthreadinglibraryfailure.Errorcode16(Deviceorresourcebusy).

报错说不能识别参数,chema,怀疑是./globals参数有问题

GGSCI(a-test30asgoldengate@qatest30)10>viewParams./GLOBALS
chemagoldengate
CheckpointTablegoldengate.checkpoint
UnlockedTrailFiles

果然写错了,chema前面少东西,真是粗心。。。
重新编辑:

GGSCI(a-test30asgoldengate@qatest30)12>viewparams./GLOBALS
GGSchemagoldengate
CheckpointTablegoldengate.checkpoint
UnlockedTrailFiles

编辑完后需要删除checkpoint table再重新添加

GGSCI(a-test30)5>DbLoginUserIdgoldengate,Passwordgoldengate
Successfullyloggedintodatabase.
GGSCI(a-test30asgoldengate@qatest30)6>AddCheckpointTable
Nocheckpointtablespecified.UsingGLOBALSspecification(goldengate.checkpoint)...
ERROR:Failedcreatingcheckpointtablegoldengate.checkpoint.
OCIErrorORA-00955:��绉板凡�辩�版��瀵硅薄浣跨��(status=955),sql<CREATETABLEgoldengate.checkpoint(group_nameVARCHAR2(8)NOTNULL,group_keyNUMBER(19)NOTNULL,seqnoNUMBER(10),rbaNUMBER(19)NOTNULL,audit_tsVARCHAR2(29),create_tsDATENOTNULL,last_update_tsDATENOTNULL,current_dirVARCHAR2(255)NOTNULL,log_bsnVARCHAR2(128),log_csnVARCHAR2(128),log_xidVARCHAR2(128),log_cmplt_csnVARCHAR2(128),log_cmplt_xidsVARCHAR2(2000),versionNUMBER(3),PRIMARYKEY(group_name,group_key))PCTFREE60>.
GGSCI(a-test30asgoldengate@qatest30)7>deleteCheckpointTable
Nocheckpointtablespecified.UsingGLOBALSspecification(goldengate.checkpoint)...
Thischeckpointtablemayberequiredforotherinstallations.Areyousureyouwanttodeletethischeckpointtable?yes
Successfullydeletedcheckpointtablegoldengate.checkpoint.
GGSCI(a-test30asgoldengate@qatest30)8>exit
[oracle@a-test30softogg1]$./ggsci
OracleGoldenGateCommandInterpreterforOracle
Version12.1.2.1.0OGGCORE_12.1.2.1.0_PLATFORMS_140727.2135.1_FBO
Linux,x64,64bit(optimized),Oracle11gonAug7201409:14:25
OperatingsystemcharactersetidentifiedasUTF-8.
Copyright(C)1995,2014,Oracleand/oritsaffiliates.Allrightsreserved.
GGSCI(a-test30)1>
GGSCI(a-test30)1>DbLoginUserIdgoldengate,Passwordgoldengate
Successfullyloggedintodatabase.
GGSCI(a-test30asgoldengate@qatest30)2>AddCheckpointTable
Nocheckpointtablespecified.UsingGLOBALSspecification(goldengate.checkpoint)...
Successfullycreatedcheckpointtablegoldengate.checkpoint.

添加完成后一定要退出重新进来
启动进程,终于可以了

GGSCI(a-test30asgoldengate@qatest30)10>infoall
ProgramStatusGroupLagatChkptTimeSinceChkpt
MANAGERRUNNING
EXTRACTRUNNINGEXT100:42:4200:00:09
EXTRACTRUNNINGPUMP100:00:0000:42:34

总结:复制粘贴之后一定要再确认一遍没有问题,出现报错可能都是因为一些基本参数没有配置正确。

猜你在找的Oracle相关文章