暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

GBase 8a MPP Cluster集群间同步工具gcluster_rsynctool

原创 灵魂摆渡者 2022-05-31
479

功能特性

异步同步。

同步以表为单位进行。

同步过程中,自动给源表加写锁(允许读、不允许写),目标表加读锁(读写均不允许)。

两套集群要求HashMap、主分片数完全一致。

已知问题

同步过程中如果宕机(主备集群宕机,或同步工具宕机),会导致表数据不一致,且状态无记录。需要外部系统在同步异常后进行恢复。

同步需由外部系统调度。同步工具不会根据主库变化自动发起同步。

元数据无法同步。

 

实例:

python gcluster_rsynctool.py --master_mpp_ip=192.168.43.10 --slave_mpp_ip=192.168.43.11 --table_list_file=t.txt --sync_mode=3 --log_level=5 --sync_vc_name=vcname000001

[gbase@lypb python gcluster_rsynctool. py 
- -master_mpp_ip=192.168.43.10 
--table list file=t.txt 
- -sync_vc name=vcn 
ameoooool 
Sync Tool 
Table [ 
vcnameoooool: 
vcnameoooool 
Sync Tool 
Sta 
test : 
End With 
t] Sync Start 
t] Sync End 
cost 
: s.376

 

[gbase@lypb —IS gcadmin 
CLUSTER STATE : 
VIRTUAL CLUSTER MODE: NORMAL 
GBASE GCWAÆ CLUSTER INFORMATION I 
NodeName I IpAdd ress I gcware I 
I gcwarel | 192.168.43.11 | OPEN I 
GBASE COORDINATOR CLUSTER INFORMATION 
NodeName I IpAddress I gcluster I DataState I 
I coordinatorl | 192.168.43.11 | OPEN I 
GBASE DATA CLUSTER INFORMATION 
NodeName I 
nodel 
IpAdd ress 
192.168.43.11 
I Distributionld 
I gnode 
I OPEN 
I syncserver I DataState I 
I OPEN I

 

CLUSTER 
VIRTUAL 
GBASE 
[gbase@lypa bin]$ gcadmln 
STATE : 
CLUSTER 
MODE : 
ACTIVE 
NORMAL 
GCWARE CLUSTER INFORMATION 
NodeName I 
IpAdd ress 
I gcware 
gcwarel | 192.168.43.1€ | OPEN 
GBASE 
NodeName 
coo rdinato rl 
NodeName 
nodel 
COORDINATOR CLUSTER INFORMATION 
IpAdd ress 
I gcluster I DataState I 
| 192.168.43.1€ | 
OPEN 
GBASE DATA 
IpAdd ress 
192 . 168 .43. 
CLUSTER 
INFORMATION 
Distributionld 
gnode 
OPEN 
syncserver 
OPEN 
I DataState I

「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论