GBase 8a 在V953版本支持多实例,如果由于某些原因需要缩容,在卸载时需要指定当前存在的调度节点信息,因为本机有多个IP。在V8和V952版本里,一个节点只能一个实例,没有这个问题。
参考
目录导航
报错样例
[gbase@gbase_rh7_003 gcinstall]$ ./unInstall.py --silent=demo_delete.options
Error: unInstall.py(line 827) -- local IPv4 addr is not a valid coordinator.
当前环境
其中105节点已经从集群datanode删除了。注意这4个IP,都在一台机器上。
[gbase@gbase_rh7_003 gcinstall]$ gcadmin
CLUSTER STATE: ACTIVE
VIRTUAL CLUSTER MODE: NORMAL
====================================
| GBASE GCWARE CLUSTER INFORMATION |
====================================
| NodeName | IpAddress | gcware |
------------------------------------
| gcware1 | 10.0.2.103 | OPEN |
------------------------------------
====================================================
| GBASE COORDINATOR CLUSTER INFORMATION |
====================================================
| NodeName | IpAddress | gcluster | DataState |
----------------------------------------------------
| coordinator1 | 10.0.2.103 | OPEN | 0 |
----------------------------------------------------
=========================================================================================================
| GBASE DATA CLUSTER INFORMATION |
=========================================================================================================
| NodeName | IpAddress | DistributionId | gnode | syncserver | DataState |
---------------------------------------------------------------------------------------------------------
| node1 | 10.0.2.103 | 2 | OPEN | OPEN | 0 |
---------------------------------------------------------------------------------------------------------
| node2 | 10.0.2.104 | 2 | OPEN | OPEN | 0 |
---------------------------------------------------------------------------------------------------------
| node4 | 10.0.2.106 | | OPEN | OPEN | 0 |
老版本配置文件
在老版本V8和V952里,删除时只需要配置要卸载的调度(coordinateHost)和数据节点(dataHost)IP即可。
[gbase@gbase_rh7_003 gcinstall]$ cat demo_delete.options
installPrefix= /opt/gbase
coordinateHost =
coordinateHostNodeID = 234,235,237
dataHost = 10.0.2.105
#existCoordinateHost =10.0.2.103
#existDataHost =10.0.2.103,10.0.2.104,10.0.2.105
#existGcwareHost=10.0.2.103
gcwareHost =
gcwareHostNodeID = 234,235,237
dbaUser = gbase
dbaGroup = gbase
dbaPwd = 'gbase1234'
#rootPwd = '111111'
#rootPwdFile = rootPwd.json
#characterSet = utf8
#sshPort = 22
[gbase@gbase_rh7_003 gcinstall]$
修改方法
在部署了多实例时,需要指定当前存在的一个调度节点的IP。经过测试,existDataHost和existGcwareHost不需要填写。
[gbase@gbase_rh7_003 gcinstall]$ cat demo_delete.options
installPrefix= /opt/gbase
coordinateHost =
coordinateHostNodeID = 234,235,237
dataHost = 10.0.2.105
existCoordinateHost =10.0.2.103
#existDataHost =10.0.2.103,10.0.2.104,10.0.2.105
#existGcwareHost=10.0.2.103
gcwareHost =
gcwareHostNodeID = 234,235,237
dbaUser = gbase
dbaGroup = gbase
dbaPwd = 'gbase1234'
#rootPwd = '111111'
#rootPwdFile = rootPwd.json
#characterSet = utf8
#sshPort = 22
[gbase@gbase_rh7_003 gcinstall]$
执行结果
顺利卸载完成
gbase@gbase_rh7_003 gcinstall]$ ./unInstall.py --silent=demo_delete.options
These GCluster nodes will be uninstalled.
CoordinateHost:
DataHost:
10.0.2.105
Are you sure to uninstall GCluster ([Y,y]/[N,n])? y
unInstall 10.0.2.105 's data successfully.
Update all cluster common conf.
10.0.2.104 update cluster common conf successfully.
10.0.2.106 update cluster common conf successfully.
10.0.2.103 update cluster common conf successfully.
Starting all gcluster nodes ...
[gbase@gbase_rh7_003 gcinstall]$