Chinaunix首页 | 论坛 | 博客
  • 博客访问: 2279868
  • 博文数量: 297
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 2200
  • 用 户 组: 普通用户
  • 注册时间: 2014-03-31 14:30
个人简介

自己慢慢积累。

文章分类

全部博文(297)

分类: Mysql/postgreSQL

2014-11-22 20:12:01

1.查看帮助
help, help add exttrail

2.显示当前的GoldenGate环境信息
show

3.查看运行状态
info all, info mgr, info extract emytest

GGSCI (center) 6> info rchuc, showch

REPLICAT   RCHUC     Last Started 2013-12-06 15:13   Status ABENDED
Checkpoint Lag       00:00:00 (updated 442:29:13 ago)
Log Read Checkpoint  File /u01/app/ggate/dirdat/zsap_chuc/re000011
                     First Record  RBA 2605820


Current Checkpoint Detail:

Read Checkpoint #1

  GGS Log Trail

这样,会显示很多信息出来,就不再贴出来
  
 
4.启动和停止服务
start mgr,stop mgr
start extract emytest,stop extract emytest
start replicat rmytest,stop replicat rmytest
如果不能停止的话,
kill extract emytest

5.历史命令
history

6.使用OBEY(自动运行一个文件)

 ggs]$ cat /home/testdb/ggs/yzhq.txt 
status manager
status mgr
[testdb@mytest ggs]$


GGSCI (mytest.mugua) 1> obey yzhq.txt

GGSCI (mytest.mugua) 2> status manager


Manager is running (IP port mytest.mugua.7809).


GGSCI (mytest.mugua) 3> status mgr


Manager is running (IP port mytest.mugua.7809).


GGSCI (mytest.mugua) 4>

7.使用shell脚本

ggsci <


[testdb@mytest ggs]$ ggsci < yzhq.txt

GoldenGate Command Interpreter for Oracle
Version 10.4.0.12 Build 001
Linux, x86, 32bit (optimized), Oracle 10 on Aug 21 2009 14:34:04

Copyright (C) GoldenGate Software, Inc. 1995-2009.
The GoldenGate software may include other code written by third parties;
details regarding such third party code, including applicable copyright,
legal and licensing notices are available at .

 

GGSCI (mytest.mugua) 1> 
Manager is running (IP port mytest.mugua.7809).


GGSCI (mytest.mugua) 2> 
Manager is running (IP port mytest.mugua.7809).


GGSCI (mytest.mugua) 3>

[testdb@mytest ggs]$

8.修改参数文件
edit params

9.参数文件存放的目录
Storing parameter files<完整路径>

10.参数文件内的语法
[,

12.查看操作的统计信息
STATS {EXTRACT | REPLICAT}
stats er*
 
13.查看GoldenGate的错误日志内容
  VIEW GGSEVT Contents

14. Deleting a process group
delete emytest

15.send命令

send extract emugua1, showtrans
send extract emugua1, status
SEND EXTRACT 进程名, SKIPTRANS <5.17.27634>
跳过事务
SEND EXTRACT 进程名, FORCETRANS <5.17.27634> 
认为该事务已经提交
send 进程名 forcestop
强制杀掉


16. alert 相关命令

--设置翻滚
alter extract EMUGUA1 etrollover

--设置抓取进程开始位置
alter EMUGUA1 extseqno 11,extrba 0

--设置投递进程开始位置
alter PMUGUA1 extseqno 11,extrba 0

--设置开始时间点
ALTER EXTRACT EMUGUA1, TRANLOG, BEGIN 2012-09-14 13:30

--设置复制进程开始位置
alter REPLICAT RMUGUA1 extseqno 10, extrba 0

阅读(1782) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~