GBase 8a卸载uninstall.py报错can not remove all coordinator nodes without remove all data nodes, please check your config

GBase 8a支持通过uninstall.py卸载集群,但如果所有的管理、调度节点都卸载了,则所有的数据节点必须全部卸载,否则就会报can not remove all coordinator nodes without remove all data nodes, please check your config的错误。

报错样例

[gbase@gbase_rh7_003 gcinstall]$ ./unInstall.py --silent=demo.options
Error: unInstall.py(line 821) -- can not remove all coordinator nodes without remove all data nodes, please check your config.

原因

查看demo.options,数据节点配置了103,104,105共三个

[gbase@gbase_rh7_003 gcinstall]$ cat demo.options
installPrefix= /opt/gbase
coordinateHost = 10.0.2.103
coordinateHostNodeID = 103
dataHost = 10.0.2.103,10.0.2.104,10.0.2.105
#existCoordinateHost =
#existDataHost =
#existGcwareHost=
gcwareHost = 10.0.2.103
gcwareHostNodeID = 103
dbaUser = gbase
dbaGroup = gbase
dbaPwd = 'gbase1234'
rootPwd = ''
#rootPwdFile = rootPwd.json
#characterSet = utf8
#dbPort = 5258
#sshPort = 22

查看集群状态,发现管理和调度只有1个,数据节点有4个 103到106.

[gbase@gbase_rh7_003 log]$ 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     |
---------------------------------------------------------------------------------------------------------
|  node3   |                10.0.2.105                |       2        | OPEN  |    OPEN    |     0     |
---------------------------------------------------------------------------------------------------------
|  node4   |                10.0.2.106                |       2        | OPEN  |    OPEN    |     0     |
---------------------------------------------------------------------------------------------------------

解决

在卸载配置文件里,填写完整的数据节点IP。 既然所有管理和数据都卸载了,则所有的数据节点也就没有保留的意义。这不是缩容,而是全部卸载。

[gbase@gbase_rh7_003 gcinstall]$ vi demo.options
[gbase@gbase_rh7_003 gcinstall]$ cat demo.options
installPrefix= /opt/gbase
coordinateHost = 10.0.2.103
coordinateHostNodeID = 103
dataHost = 10.0.2.103,10.0.2.104,10.0.2.105,10.0.2.106
#existCoordinateHost =
#existDataHost =
#existGcwareHost=
gcwareHost = 10.0.2.103
gcwareHostNodeID = 103
dbaUser = gbase
dbaGroup = gbase
dbaPwd = 'gbase1234'
rootPwd = ''
#rootPwdFile = rootPwd.json
#characterSet = utf8
#dbPort = 5258
#sshPort = 22

再次执行卸载,成功卸载。

[gbase@gbase_rh7_003 gcinstall]$ ./unInstall.py --silent=demo.options


These GCluster nodes will be uninstalled.
CoordinateHost:
10.0.2.103
DataHost:
10.0.2.103    10.0.2.104    10.0.2.105    10.0.2.106
GcwareHost:
10.0.2.103
Are you sure to uninstall GCluster ([Y,y]/[N,n])? y
unInstall 10.0.2.103 's gcware successfully.
unInstall 10.0.2.103 's coordinate successfully.
unInstall 10.0.2.103 's data successfully.
unInstall 10.0.2.104 's data successfully.
unInstall 10.0.2.105 's data successfully.
unInstall 10.0.2.106 's data successfully.
[gbase@gbase_rh7_003 gcinstall]$

发表评论

您的电子邮箱地址不会被公开。