当前位置:网站首页>Ogg synchronize MySQL data to greenplus
Ogg synchronize MySQL data to greenplus
2022-06-29 14:36:00 【swj23333】
This article has participated in 「 New people's creation ceremony 」 Activities , Start the road of nuggets creation together .
Source end :
ogg Installation , You can download and decompress them directly on the official website to the corresponding directory , Address :www.oracle.com/technetwork… Version is 12.3.0.1.5
mysql Configure environment variables :
export GG_HOME=/home/ogg/
export PATH=GG_HOME export LD_LIBRARY_PATH=JAVA_HOME/jre/lib/amd64/libjsig.so:JAVA_HOME/jre/lib/amd64/server:$JAVA_HOME/jre/lib/amd64
mysql Turn on bin-log stay my.conf Add... To the configuration file
[mysqld]
server_id=1 log-bin=/home/mysql3307/mysql-5.6.33/logs/log-bin binlog_format=row
restart mysql
Get into ogg The installation directory , Execute the following command : Get into ogg
ggsci
Create subdirectories
create subdirs
Edit extraction process
edit param ext_cshy
Here is the content :
EXTRACT ext_cshy
setenv (MYSQL_HOME="/home/mysql3307/mysql-5.6.33") setenv (NLS_LANG="AMERICAN_AMERICA.UTF8") tranlogoptions altlogdest /home/mysql3307/mysql-5.6.33/data/slave3307_bin.index sourcedb [email protected]:xxxx USERID xxxx, PASSWORD xxxx DISCARDROLLOVER ON FRIDAY DISCARDFILE /home/ogg/dirrpt/ext_cshy.dsc, APPEND, MEGABYTES 1024 REPORTCOUNT EVERY 1 MINUTES, RATE GETUPDATEBEFORES UPDATERECORDFORMAT COMPACT GETTRUNCATES EXTTRAIL /home/ogg/dirdat/cs table aisino.wechat_mp_order; table aisino.wechat_mp_order_item;
Add extraction process
add extract ex_test,tranlog,begin now
add exttrail /home/ogg/dirdat/te,extract ex_test
Edit posting process
edit param pum_cshy
Here is the content :
EXTRACT pum_cshy
SETENV (NLS_LANG = "AMERICAN_AMERICA.UTF8") PASSTHRU RMTHOST 192.168.x.xx, MGRPORT 7809 RMTTRAIL /data/ogg/dirdat/cs table aisino.wechat_mp_order; table aisino.wechat_mp_order_item add extract dp_test,exttrailsource /opt/ogg/dirdat/te
Add delivery process ( The path is the directory path posted to the remote )
add rmttrail /opt/ogg/dirdat/te,extract dp_test
Edit the mapping file
edit param def_cshy
Here is the content :
defsfile /home/ogg/dirdef/def_cshy.prm
sourcedb [email protected]:xxxx, userid xxxx,password xxxx table aisino.wechat_mp_order; table aisino.wechat_mp_order_item;
sign out ogg
exit
Generate the corresponding description file by mapping the configuration file
./defgen paramfile ./dirprm/def_cshy.prm
Copy ./dirdef Under the defgen.prm To the target end ${OGG_HOME}/dirdef Next
Target end :
install ogg Version is 12.3.0.1.2
Edit replication process
edit rep_test
Here is the content :
REPLICAT rep_cshy
TARGETDB LIBFILE libggjava.so SET property=/data/ogg/dirprm/kafka_cshy.props SOURCEDEFS /data/ogg/dirdef/def_cshy.prm REPORTCOUNT EVERY 1 MINUTES, RATE GROUPTRANSOPS 10000 GETTRUNCATES MAP aisino., TARGET cshy.;
Add replication process
add replicat rep_test,exttrail /opt/ogg/dirdat/te,checkpointtable ogg.checkpoint
To configure kafka The configuration file dirprm/kafka_cshy.props Here is the content :
gg.handlerlist = kafkahandler
gg.handler.kafkahandler.type=kafka gg.handler.kafkahandler.KafkaProducerConfigFile=custom_kafka_producer.properties #The following resolves the topic name using the short table name gg.handler.kafkahandler.topicMappingTemplate=ogg_cshy #The following selects the message key using the concatenated primary keys gg.handler.kafkahandler.format.includePrimaryKeys=true gg.handler.kafkahandler.format=json gg.handler.kafkahandler.BlockingSend =false gg.handler.kafkahandler.includeTokens=false gg.handler.kafkahandler.mode=op goldengate.userexit.writers=javawriter javawriter.stats.display=TRUE javawriter.stats.full=TRUE gg.log=log4j gg.log.level=INFO gg.report.time=30sec #Sample gg.classpath for Apache Kafka gg.classpath=/data/ogg/dirprm/:/home/gpadmin/software/kafka_2.12-2.1.0/libs/:/data/ogg/:/data/ogg/lib/ #Sample gg.classpath for HDP #gg.classpath=/etc/kafka/conf:/usr/hdp/current/kafka-broker/libs/* javawriter.bootoptions=-Xmx512m -Xms32m -Djava.class.path=ggjava/ggjava.jar
start-up Source end :
ggsci
strat ext_cshy start pum_cshy
Destination :
ggsci start rep_cshy
have access to view report Process name View startup log
kafka To greenplum You need to write a synchronization program
边栏推荐
- How goby exports scan results
- QRCode自定义二维码中间图片
- Wechat applet: new and exclusive cloud development wechat group contacts
- 【blackduck】jenkins下配置指定的synopsys-detect扫描版本
- 【VEUX开发者工具的使用-getters使用】
- 揭秘!付费会员制下的那些小心机!
- 吐血整理:一份不可多得的架构师图谱!
- Detailed explanation of redis sentry mechanism
- 《canvas》之第10章 canvas路径
- 织梦dedecms资源素材教程下载网站模板源码(带手机移动端)附安装教程
猜你喜欢

部署搭建decentraland流程讲解

Unity SplashImage 缩放问题

微信小程序:图片秒加水印制作生成

Wechat applet: Halloween avatar box generation tool

分布式唯一 ID 生成方案浅谈

Source code of campus secondary market

uniApp问题清单与经验

Applet Wechat: un nouveau réseau exclusif de microgroupes de développement de Cloud

纳人才,谋发展 | 人大金仓喜获“最佳雇主校招案例奖”

【jenkins】pipeline控制多job顺序执行,进行定时持续集成
随机推荐
【关联分析实战篇】为什么 BI 软件都搞不定关联分析
redis 分片集群搭建与使用教程
openGauss社区成立SIG KnowledgeGraph
Istio网格中访问外部服务方法
goby全端口扫描
uniApp问题清单与经验
VeeamBackup&Replication简介
systemd调试
tcpdump如何对特定的tcp标志位进行过滤
微信小程序:大红喜庆版UI猜灯谜又叫猜字谜
MySQL数据库:分区Partition
Transport layer user datagram protocol (UDP)
强大、优秀的文件管理软件评测:图片管理、书籍管理、文献管理
MySQL数据库:drop、truncate、delete的区别
在同花顺上开户安全吗 开户在哪里申请
《canvas》之第12章 其他应用
MySQL数据库:使用show profile命令分析性能
每周 Postgres 世界动态 2022w25
喜迎市科协“十大”•致敬科技工作者 | 卢毅:守护电网传输安全的探索者
你还在用命令看日志?快用 Kibana 吧,一张图胜过千万行日志