转自:http://blog.csdn.net/lemontree1123/article/details/46603549

manager参数:

AUTOSTART:指定在mgr启动时自动启动那些进程.
AUTOSTART ER *
AUTOSTART extract extsz 
 
AUTORESTART:指定在mgr可以定时重启那些进程。可以在网络中断等故障恢复后自动重起,避免人工干预.
AUTORESTART ER *, WAITMINUTES 5, RETRIES 3
 
DYNAMICPORTLIST:指定GoldenGate可以使用那些端口接受extract发送过来的数据.
DYNAMICPORTLIST 7840-7850
 
PORT:制定GoldenGate的mgr进程使用哪个 TCP/IP端口侦听请求.
PORT 7809
 
LAGCRITICAL:指定认为超过此时间即为严重错误的延迟最大值,如果延迟达到此时间值则会在ggserr.log里面写入一条error信息
LAGCRITICALMINUTES 10 
 
LAGREPORT:指定在ggserr.log中报告延迟的时间间隔.
LAGREPORTHOURS 1 
 
PURGEOLDEXTRACTS :定义自动删除过时的队列以节省硬盘空间。一般按照两个规则来删除:首先,要满足检查点要求,没有使用过的队列不能删除,保证无数据丢失;其次,可以保留一定的天数。只有当已经使用过且超过设定的天数后的队列会被自动删除。 
purgeoldextracts /backup/goldengate/dirdat/*,usecheckpoints, minkeepdays 7
 
 
抽取参数:
CHECKPARAMS:如果加入该参数,表示下次运行只是检查一下语法,并不实际运行进程。
注意:该命令只能检查一些简单语法,并不能保证参数文件是完全正确的。
COMMENT:注释行,也可以用两个中划线--代替.--checkparams表示本行已经被注释掉 
EXTRACT :定义抽取进程的名字 
OBEY :可以将外部文件的内容包含到本参数文件中来。用于将一些可以重复利用的参数文件部分内容隔离出来,便于统一修改。
Obey tables.txt
TABLEEXCLUDE :定义所需要排除的表。如果在table里面定义了使用通配符,那么可以使用该参数定义排除掉其中的部分表。如:
tableexclude ctais2.TMP_*;
tableexclude ctais2.TEMPTAB; 
GETUPDATEAFTERS | IGNOREUPDATEAFTERS 是否在队列中写入后影像,缺省复制 
GETUPDATEBEFORES | IGNOREUPDATEAFTERS 是否在队列中写入前影像,缺省不复制 
GETUPDATES | IGNOREUPDATES 是否复制update操作,缺省复制
GETDELETES | IGNOREDELETES 是否复制delete操作,缺省复制
GETINSERTS | IGNOREINSERTS 是否复制insert操作,缺省复制
GETRUNCATES| IGNORETRUNCATES 是否复制truncate操作,缺省不复制.
RMTHOST 指定目标系统及其GoldenGate Manager进程的端口号,也用于定义是否使用压缩进行传输。
rmthost  99.16.1.12,mgrport 7809, compress
RMTTRAIL 指定写入到目标端的哪个队列。 
EXTTRAIL 指定写入到本地的哪个队列。 
SQLEXEC 在extract运行时首先运行一个sql语句。sqlexec "Alter session set constraints=deferred" 
PASSTHRU 禁止extract与数据库交互,适用于Data Pump传输进程(dpeXX)
GETENV | SETENV 针对extract进程设定系统环境变量。 setenv ( NLS_LANG = AMERICAN_AMERICA.ZHS16GBK ) 
REPORT 定义自动定时报告。 REPORT AT 01:59 
STATOPTIONS 定义每次使用stat时统计数字是否需要重置
REPORTCOUNT 报告已经处理的纪录条数统计数字
TLTRACE 打开对于数据库日志的跟踪日志 
TRACE/TRACE2 打开对GoldenGate进程的跟踪日志,一般用于调试。 
DISCARDFILE 定义discard文件位置,如果处理中有纪录出错会写入到此文件中
discardfile /oradata/goldengate/repkj.dsc,append,megabytes 100m
NUMFILES 定义本extract为最大多少张表预留空间,缺省为500,超过500张表需要设定一个比实际表数略大的值
numfiles 3000
PURGEOLDEXTRACTS 同mgr进程,可以设置自动删除队列,建议在mgr设置
REPORTROLLOVER 设定切换一个日志的时间和间隔 reportrollover at 02:00
TRANSMEMORY 设定GoldenGate的抽取进程能够使用的内存大小。如下参数指定本进程最大只能占用2G内存,其中每个事务最大占用内存不能超过500M,如果超过则使用指定目录作为虚拟内存,该目录下的单个文件大小为4G,最多只能在该目录下占用8G空间作为缓存。
transmemory directory (/backup/goldengate/dirtmp,8G,4G),ram 2G,transram 500M
DBOPTIONS  指定对于某种特定数据库所需要的特殊参数。
[SOURCEDB,] USERID ,PASSWORD 指定所要登陆的数据库名称,用户名和密码。对于oracle无需指定sourcedb,直接指定用户名和密码即可。
Userid goldengate, password goldengate 
TRANLOGOPTIONS 指定在解析数据库日志时所需要的特殊参数。例如,对于裸设备,可能需要加入下列参数
tranlogoptions rawdeviceoffset 0 
tranlogoptions altarchivelogdest instance sidname /arch  --指定归档日志所在
WARNLONGTRANS 指定对于超过一定时间的长交易可以在ggserr.log里面写入警告信息。例如,每隔30分钟检查一次长交易,对于超过12个小时的进行告警:--warnlongtrans 12h, checkintervals 30m
 
 
复制参数:
CHECKPARAMS 检查参数语法然后停止
COMMENT 注释行
REPLICAT 定义进程名称
USERID 指定登陆目标数据库的用户名和密码
OBEY 将外部文件包含到参数文件中
ASSUMETARGETDEFS 假定两端数据结构一致使用此参数
SOURCEDEFS 假定两端数据结构不一致,使用此参数指定源端的数据结构定义文件。该文件需要由GoldenGate工具产生
MAPEXCLUDE 用于使用在map中使用*匹配时排除掉指定的表,类似于于源端的tablexclude
mapexclude CTAIS2.JC_GY_SWWSWH
MAP ctais2.* ,TARGET ctais2.*; 
 
GETDELETES | IGNOREDELETES 是否复制delete操作,缺省为复制
GETUPDATES |IGNOREUPDATES  是否复制update操作,缺省为复制
GETINSERTS | IGNOREINSERTS 是否复制insert操作,缺省为复制
GETUPDATEAFTERS | IGNOREUPDATEAFTERS 是否读取后影像,缺省为读取
GETUPDATEBEFORES | IGNOREUPDATEBEFORES 是否读取前影像,缺省为不读取
GETTRUNCATES | IGNORETRUNCATES 是否复制truncate操作,缺省为不复制
allownoopupdates 允许执行无实际变化的update。例如,update a=a会纪录一条update,但是没有后影像,无法正确构筑where语句
REPERROR 定义出错以后replicat的响应,一般可以定义为两种:Abend,即一旦出现错误即停止复制,此为缺省配置;Discard,出现错误后继续复制,只把错误的数据放到discard文件中。 
DISCARDFILE 定义出错数据的输出文件。当数据出现错误后,可以用于查找错误原因 
discardfile /oradata/goldengate/dirrpt/repsz.dsc,append, megabytes 10
HANDLECOLLISIONS 自动过滤重复时段的数据冲突,用于不能停机执行初始化。打开该参数后不会将数据错误报到discard文件中。 
DYNAMICRESOLUTION 使replicat动态解析表的结构,加快启动速度。缺省为每次启动解析所有要复制表的结构 
SQLEXEC 调用存储过程或者执行sql语句。可以将返回值作为依据进行过滤条件,或者用户改变session变量。
GROUPTRANSOPS 将小的交易合并成为一个大的交易进行提交,减少提交次数,降低系统IO消耗。
MAXTRANSOPS 将大交易拆分,每若干条纪录提交一次 maxtransops 1000
BATCHSQL 针对批处理中针对某个表的大批量重复操作进行优化,提高批处理的处理速度。 
DBOPTIONS 定义与数据库类型相关的特殊处理方式。
NUMFILES 定义进程中表的最大数据量,缺省为 500.
PURGEOLDEXTRACTS 定义自动删除队列,一般建议在mgr进程配置。
 
错误定位时经常使用下面三个参数:
nodynsql
nobinarychars
showsyntax
 
 
DYNSQL | NODYNSQL
Valid for Replicat
Use the DYNSQL and NODYNSQL parameters to control the way that SQL statements are 
formed. With NODYNSQL, Replicat uses literal SQL statements with the bind variables 
resolved. With DYNSQL, the default, Replicat uses dynamic SQL to compile a statement 
once, and then execute it many times with different bind variables. 
● Statement with DYNSQL:
UPDATE <table> ... WHERE ID = :B
● Statement with NODYNSQL: 
UPDATE <table> ... WHERE ID = ‘1234’
In most environments, using DYNSQL yields the best efficiency and most throughput. 
However, in isolated instances, using NODYNSQL has proven faster and more efficient. Try 
NODYNSQL only if Replicat throughput appears unsatisfactory.
Do not use DYNSQL when replicating to target databases that do not support dynamic SQL.
When using NODYNSQL, you must also use the NOBINARYCHARS parameter。
Oracle GoldenGate for MySQL does not support LOB replication in NODYNSQL mode. 
Default DYNSQL
Syntax DYNSQL | NODYNSQL
 
BINARYCHARS | NOBINARYCHARS
Valid for Extract and Replicat
Use BINARYCHARS and NOBINARYCHARS to control whether character data is treated as binary data or null-terminated strings.
BINARYCHARS, the default, maintains data the way it was entered in the source table. This 
ensures proper processing in cases when a column in the source or target database is 
defined as a character column and it is possible that binary characters could be entered 
into that column. BINARYCHARS is not compatible with the BULKLOAD parameter (direct-bulk load); use NOBINARYCHARS.
NOBINARYCHARS can cause Oracle GoldenGate to interpret a binary character to be the end 
of the data in that column. If there is more data after the binary data, it is not processed 
by Oracle GoldenGate, compromising data integrity. NULL characters cause this to happen, 
as well as any character defined with the DELIMITER option of FORMATASCII. Unless there is 
good reason to use NOBINARYCHARS, leaving the default set to BINARYCHARS is recommended so 
that data is maintained the way it was entered in the source table. Before using 
NOBINARYCHARS, contact Oracle Support.
BINARYCHARS and NOBINARYCHARS are table-specific. One parameter remains in effect for all 
subsequent TABLE or MAP statements until the other is encountered.
Default BINARYCHARS
Syntax BINARYCHARS | NOBINARYCHARS
 
SHOWSYNTAX
Valid for Replicat
Use the SHOWSYNTAX parameter to start an interactive session where you can view each Replicat SQL statement before it is applied. By viewing the syntax of SQL statements that failed, you might be able to diagnose the cause of the problem. For example, you could find out that the WHERE clause is using a non-indexed column.Requirements for using SHOWSYNTAX
● The first time that you use SHOWSYNTAX, request guidance from an Oracle Support analyst. It is a debugging parameter and can cause unwanted results if used improperly. It requires manual intervention, so automated processing is suspended, and it slows down processing, which can cause backlogs and latency.
● To use SHOWSYNTAX, Replicat must be started from the command shell of the operating system. Do not use SHOWSYNTAX if Replicat is started through GGSCI. 
● Use SHOWSYNTAX in a test environment. Create duplicates of your Replicat groups and target tables so that the production environment is not affected. 
Using SHOWSYNTAX
1. In the Replicat parameter file, include the following parameters in the order shown 
here, each on its own line:
❍ NOBINARYCHARS
❍ NODYNSQL
❍ SHOWSYNTAX
NOTE NOBINARYCHARS is an undocumented parameter that causes Oracle GoldenGate 
to treat binary data as a null-terminated string. Contact Oracle Support before 
using it. NODYNSQL causes Replicat to use literal SQL statements instead of using dynamic SQL with bind variables. 
2. From the Oracle GoldenGate home directory, start Replicat from the command shell of the operating system using the syntax shown here. Do not specify a reportfile option. 
Output must go to screen.
replicat paramfile dirprm/<Replicat_name>.prm 
3. The first SQL statement is displayed with some prompts.
❍ Choose Keep Displaying (the default) to execute the current statement and display the 
next one.
❍ Choose Stop Display to resume normal processing and stop printing SQL statements 
to screen.
4. When finished viewing syntax, remove SHOWSYNTAX, NOBINARYCHARS, and NODYNSQL from 
the parameter file.
Default None
Syntax SHOWSYNTAX
 
 
11.1版本的OGG Bounded Recovery BR参数可能会有很多问题,最好关闭,然后配合操作系统监控长事务,定时杀掉长事务,避免出现问题。然后
配置CACHESZIE为一个值,避免影响系统性能。
 
 
tranlogoptions logretention disabled
tranlogoptions dblogreader
DBLOGREADER :
(Oracle) Valid for Extract in classic capture mode.Causes Extract to use a newer ASM API that is available as 
of Oracle 10.2.0.5 and later 10g R2 versions, and Oracle 11.2.0.2 and later 11g R2 versions (but not in Oracle 11g R1 versions). This API uses the database server to access the redo and archive logs, instead of connecting directly to the Oracle ASM instance. The database must contain the 
libraries that contain the API modules and must be running.To use this feature, the Extract database user must have SELECT ANY TRANSACTIONprivilege. When used, DBLOGREADER enables Extract to use a read size of up to 4 MB in size. This is controlled with the DBLOGREADERBUFSIZE option
The maximum read size when using the default OCI buffer is 28672 bytes. This is controlled by the ASMBUFSIZE option.
A larger buffer may improve the performance of Extract when redo rate is high. 
When using DBLOGREADER, do not use the ASMUSER and ASMPASSWORD options of TRANLOGOPTIONS. The API uses the user and password specified with the USERID parameter。

goldengate一些参数整理的更多相关文章

  1. Oracle GoldenGate常用参数

    OGG(Oracle GoldenGate)参数介绍 所有的GoldenGate进程均有参数文件 Manager Extract Replicat Utilities 所有参数均有缺省配置 实际应用只 ...

  2. $_SERVER的详细参数整理下

    PHP编程中经常需要用到一些服务器的一些资料,特把$_SERVER的详细参数整理下,方便以后使用. $_SERVER['PHP_SELF'] #当前正在执行 脚本的文件名,与 document roo ...

  3. String格式化参数整理

    Java String格式话参数整理如下: conversion:转换格式,可选的格式有: d 整数型(十进制) c Unicode字符 b Boolean值 s String f 浮点数(十进制) ...

  4. hadoop作业调优参数整理及原理

    hadoop作业调优参数整理及原理 10/22. 2013 1 Map side tuning参数 1.1 MapTask运行内部原理 当map task开始运算,并产生中间数据时,其产生的中间结果并 ...

  5. Oracle GoldenGate常用参数详解

    Oracle GoldenGate常用参数详解http://blog.itpub.net/28389881/viewspace-2564461/

  6. Hbase集群搭建及所有配置调优参数整理及API代码运行

    最近为了方便开发,在自己的虚拟机上搭建了三节点的Hadoop集群与Hbase集群,hadoop集群的搭建与zookeeper集群这里就不再详细说明,原来的笔记中记录过.这里将hbase配置参数进行相应 ...

  7. Win32 API中的user32.dll中的ShowWindow方法参数整理

    在使用ShowWindow方法来设置窗体的状态时,由于不知道参数值,用起来非常容易混乱,所以整理了以下其参数的枚举值,方便以后的的使用.   public class User32API { #reg ...

  8. JVM性能调优2:JVM性能调优参数整理

    序号 参数名 说明 JDK 默认值 使用过 1 JVM执行模式 2 -client-server 设置该JVM运行与Client 或者Server Hotspot模式,这两种模式从本质上来说是在JVM ...

  9. HttpWebRequest上传多文件和多参数——整理

    1.整理HttpWebRequest上传多文件和多参数.较上一个版本,更具普适性和简易型.注意(服务方web.config中要配置)这样就可以上传大文件了 <system.webServer&g ...

随机推荐

  1. 「2013-9-5」Configure WingIDE for better display of East Asian Glyphs

    很久没写软件配置相关的博客了.这次对于 WingIDE 在 Windows 下的字体配置,折腾了好一阵子,略曲折,也反映了「不清楚原理和背景的情况下,盲人摸象的效率低下是必然」这条放之四海而皆准的赤果 ...

  2. Titanium系列--我常用的Titanium的快捷键(持续更新中。。)

    Titanium快捷键: (注:Titanium属于eclipse系列的IDE) ctrl + shift + r 快速打开 ctrl + shift + e / ctrl + e 打开之前的文件 c ...

  3. linux samba 服务器 简单配置

    1. rpm -qa|grep samba 查看是否有samba 2.使用yum -y install samba 安装samba 服务 进入/etc/samba/ 使用vi smb.conf 修改配 ...

  4. 6.4 APK包限制

    Google 2015年 9月28日公告:为了Android开发商可以制作出更加复杂的app和游戏,Google Play游戏包体(APK)大小由原来的50MB提高到100MB.但是针对Android ...

  5. oracle11g数据库的安装以及安装之后的配置

    1.按照正常的顺序进行安装,然后安装完成后可以对用户进行管理,(设置sys  sysmanager的口令,激活scott的用户并设置新密码) 这一步没什么好多的,关键是进行安装完成之后的配置,这个就比 ...

  6. Jupyter 服务开发指南

    1. 取kylin 数据 import requests import pandas as pd def getDtu(dtuid,addr): sqlData = '{ "sql" ...

  7. C#手动做一个负载均衡服务器

    思路 负载均衡服务器最出名的当数 Nginx了.Nginx服务器通过异步的方式把连接转发给内网和N个服务器,用来分解单台应用服务器的压力,了解了原理及场景后,用C#来实现一个.思路如下: 1. 使用一 ...

  8. QT自定义精美换肤界面

    陆陆续续用QT开发过很多项目,也用QT写过不少私活项目,也写过N个工具,一直梦寐以求能像VC一样可以很方便的有个自定义的界面,QSS的强大让我看到了很好的希望,辗转百度谷歌无数次,一直搜索QT相关的换 ...

  9. 不要过早退出循环 while(1){no break}

    我们在尝试新的事物的时候,总是会遇到各种各样的困难,不同的人会在碰壁不同的次数之后退出.用程序员喜欢的话来说就是,我们都在for循环,区别在于你是什么情况下break的.有的人退出阈值高,这是能坚持的 ...

  10. C#与数据库访问技术总结(十一)之数据阅读器(DataReader)1

    数据阅读器 当执行返回结果集的命令时,需要一个方法从结果集中提取数据. 处理结果集的方法有两个: 第一,使用数据阅读器(DataReader): 第二,同时使用数据适配器(Data Adapter)和 ...