add cluster admin help (#8924)

add cluster admin help
This commit is contained in:
jiafeng.zhang
2022-04-13 09:47:12 +08:00
committed by GitHub
parent b33ab960a8
commit 3b8ca4b035
22 changed files with 792 additions and 2 deletions

View File

@ -26,10 +26,45 @@ under the License.
## ALTER-SYSTEM-ADD-BACKEND
### Name
ALTER SYSTEM ADD BACKEND
### Description
This statement is used to manipulate nodes within a system. (Administrator only!)
grammar:
```sql
-- Add nodes (add this method if you do not use the multi-tenancy function)
ALTER SYSTEM ADD BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
-- Add idle nodes (that is, add BACKEND that does not belong to any cluster)
ALTER SYSTEM ADD FREE BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
-- Add nodes to a cluster
ALTER SYSTEM ADD BACKEND TO cluster_name "host:heartbeat_port"[,"host:heartbeat_port"...];
````
illustrate:
1. host can be a hostname or an ip address
2. heartbeat_port is the heartbeat port of the node
3. Adding and deleting nodes is a synchronous operation. These two operations do not consider the existing data on the node, and the node is directly deleted from the metadata, please use it with caution.
### Example
1. Add a node
```sql
ALTER SYSTEM ADD BACKEND "host:port";
````
1. Add an idle node
```sql
ALTER SYSTEM ADD FREE BACKEND "host:port";
````
### Keywords
ALTER, SYSTEM, ADD, BACKEND

View File

@ -0,0 +1,57 @@
---
{
"title": "ALTER-SYSTEM-ADD-BROKER",
"language": "en"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-ADD-BROKER
### Name
ALTER SYSTEM ADD BROKER
### Description
This statement is used to add a BROKER node. (Administrator only!)
grammar:
```sql
ALTER SYSTEM ADD BROKER broker_name "broker_host1:broker_ipc_port1","broker_host2:broker_ipc_port2",...;
````
### Example
1. Add two brokers
```sql
ALTER SYSTEM ADD BROKER "host1:port", "host2:port";
````
### Keywords
ALTER, SYSTEM, ADD, FOLLOWER
### Best Practice

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-ADD-FOLLOWER
### Name
ALTER SYSTEM ADD FOLLOWER
### Description
The change statement is to increase the node of the FOLLOWER role of FRONTEND, (only for administrators!)
grammar:
```sql
ALTER SYSTEM ADD FOLLOWER "follower_host:edit_log_port"
````
illustrate:
1. host can be a hostname or an ip address
2. edit_log_port : edit_log_port in its configuration file fe.conf
### Example
1. Add a FOLLOWER node
```sql
ALTER SYSTEM ADD FOLLOWER "host_ip:9010"
````
### Keywords
ALTER, SYSTEM, ADD, FOLLOWER

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-ADD-OBSERVER
### Name
ALTER SYSTEM ADD OBSERVER
### Description
The change statement is to increase the node of the OBSERVER role of FRONTEND, (only for administrators!)
grammar:
```sql
ALTER SYSTEM ADD OBSERVER "follower_host:edit_log_port"
````
illustrate:
1. host can be a hostname or an ip address
2. edit_log_port : edit_log_port in its configuration file fe.conf
### Example
1. Add an OBSERVER node
```sql
ALTER SYSTEM ADD OBSERVER "host_ip:9010"
````
### Keywords
ALTER, SYSTEM, ADD, OBSERVER

View File

@ -26,10 +26,35 @@ under the License.
## ALTER-SYSTEM-DECOMMISSION-BACKEND
### Name
ALTER SYSTEM DECOMMISSION BACKEND
### Description
The node offline operation is used to safely log off the node. The operation is asynchronous. If successful, the node is eventually removed from the metadata. If it fails, the logout will not be done (only for admins!)
grammar:
```sql
ALTER SYSTEM DECOMMISSION BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
````
illustrate:
1. host can be a hostname or an ip address
2. heartbeat_port is the heartbeat port of the node
3. The node offline operation is used to safely log off the node. The operation is asynchronous. If successful, the node is eventually removed from the metadata. If it fails, the logout will not be completed.
4. You can manually cancel the node offline operation. See CANCEL DECOMMISSION
### Example
1. Offline two nodes
```sql
ALTER SYSTEM DECOMMISSION BACKEND "host1:port", "host2:port";
````
### Keywords
ALTER, SYSTEM, DECOMMISSION, BACKEND

View File

@ -26,10 +26,34 @@ under the License.
## ALTER-SYSTEM-DROP-BACKEND
### Name
ALTER SYSTEM DROP BACKEND
### Description
This statement is used to delete the BACKEND node (administrator only!)
grammar:
```sql
ALTER SYSTEM DROP BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...]
````
illustrate:
1. host can be a hostname or an ip address
2. heartbeat_port is the heartbeat port of the node
3. Adding and deleting nodes is a synchronous operation. These two operations do not consider the existing data on the node, and the node is directly deleted from the metadata, please use it with caution.
### Example
1. Delete two nodes
```sql
ALTER SYSTEM DROP BACKEND "host1:port", "host2:port";
````
### Keywords
ALTER, SYSTEM, DROP, BACKEND

View File

@ -0,0 +1,66 @@
---
{
"title": "ALTER-SYSTEM-DROP-BROKER",
"language": "en"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-DROP-BROKER
### Name
ALTER SYSTEM DROP BROKER
### Description
This statement is to delete the BROKER node, (administrator only)
grammar:
```sql
-- Delete all brokers
ALTER SYSTEM DROP ALL BROKER broker_name
-- Delete a Broker node
ALTER SYSTEM DROP BROKER broker_name "host:port"[,"host:port"...];
````
### Example
1. Delete all brokers
```sql
ALTER SYSTEM DROP ALL BROKER broker_name
````
2. Delete a Broker node
```sql
ALTER SYSTEM DROP BROKER broker_name "host:port"[,"host:port"...];
````
### Keywords
ALTER, SYSTEM, DROP, FOLLOWER
### Best Practice

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-DROP-FOLLOWER
### Name
ALTER SYSTEM DROP FOLLOWER
### Description
The change statement is to increase the node of the FOLLOWER role of FRONTEND, (only for administrators!)
grammar:
```sql
ALTER SYSTEM DROP FOLLOWER "follower_host:edit_log_port"
````
illustrate:
1. host can be a hostname or an ip address
2. edit_log_port : edit_log_port in its configuration file fe.conf
### Example
1. Add a FOLLOWER node
```sql
ALTER SYSTEM DROP FOLLOWER "host_ip:9010"
````
### Keywords
ALTER, SYSTEM, DROP, FOLLOWER

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-DROP-OBSERVER
### Name
ALTER SYSTEM DROP OBSERVER
### Description
The change statement is to increase the node of the OBSERVER role of FRONTEND, (only for administrators!)
grammar:
```sql
ALTER SYSTEM DROP OBSERVER "follower_host:edit_log_port"
````
illustrate:
1. host can be a hostname or an ip address
2. edit_log_port : edit_log_port in its configuration file fe.conf
### Example
1. Add a FOLLOWER node
```sql
ALTER SYSTEM DROP OBSERVER "host_ip:9010"
````
### Keywords
ALTER, SYSTEM, DROP, OBSERVER

View File

@ -0,0 +1,79 @@
---
{
"title": "ALTER-SYSTEM-MODIFY-BACKEND",
"language": "en"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-MODIFY-BACKEND
### Name
ALTER SYSTEM MKDIFY BACKEND
### Description
Modify BE node properties (administrator only!)
grammar:
```sql
ALTER SYSTEM MODIFY BACKEND "host:heartbeat_port" SET ("key" = "value"[, ...]);
````
illustrate:
1. host can be a hostname or an ip address
2. heartbeat_port is the heartbeat port of the node
3. Modify BE node properties The following properties are currently supported:
- tag.location: resource tag
- disable_query: query disable attribute
- disable_load: import disable attribute
### Example
1. Modify the resource tag of BE
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("tag.location" = "group_a");
````
2. Modify the query disable property of BE
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("disable_query" = "true");
````
3. Modify the import disable property of BE
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("disable_load" = "true");
````
### Keywords
ALTER, SYSTEM, ADD, BACKEND
### Best Practice

View File

@ -26,13 +26,31 @@ under the License.
## CANCEL-ALTER-SYSTEM
### Name
CANCEL DECOMMISSION
### Description
This statement is used to undo a node offline operation. (Administrator only!)
grammar:
```sql
CANCEL DECOMMISSION BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
````
### Example
1. Cancel the offline operation of both nodes:
```sql
CANCEL DECOMMISSION BACKEND "host1:port", "host2:port";
````
### Keywords
CANCEL, ALTER, SYSTEM
CANCEL, DECOMMISSION
### Best Practice

View File

@ -26,10 +26,45 @@ under the License.
## ALTER-SYSTEM-ADD-BACKEND
### Name
ALTER SYSTEM ADD BACKEND
### Description
该语句用于操作一个系统内的节点。(仅管理员使用!)
语法:
```sql
1) 增加节点(不使用多租户功能则按照此方法添加)
ALTER SYSTEM ADD BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
2) 增加空闲节点(即添加不属于任何cluster的BACKEND)
ALTER SYSTEM ADD FREE BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
3) 增加节点到某个cluster
ALTER SYSTEM ADD BACKEND TO cluster_name "host:heartbeat_port"[,"host:heartbeat_port"...];
```
说明:
1. host 可以是主机名或者ip地址
2. heartbeat_port 为该节点的心跳端口
3. 增加和删除节点为同步操作。这两种操作不考虑节点上已有的数据,节点直接从元数据中删除,请谨慎使用。
### Example
1. 增加一个节点
```sql
ALTER SYSTEM ADD BACKEND "host:port";
```
1. 增加一个空闲节点
```sql
ALTER SYSTEM ADD FREE BACKEND "host:port";
```
### Keywords
ALTER, SYSTEM, ADD, BACKEND

View File

@ -0,0 +1,57 @@
---
{
"title": "ALTER-SYSTEM-ADD-BROKER",
"language": "zh-CN"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-ADD-BROKER
### Name
ALTER SYSTEM ADD BROKER
### Description
该语句用于添加一个 BROKER 节点。(仅管理员使用!)
语法:
```sql
ALTER SYSTEM ADD BROKER broker_name "broker_host1:broker_ipc_port1","broker_host2:broker_ipc_port2",...;
```
### Example
1. 增加两个 Broker
```sql
ALTER SYSTEM ADD BROKER "host1:port", "host2:port";
```
### Keywords
ALTER, SYSTEM, ADD, FOLLOWER
### Best Practice

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-ADD-FOLLOWER
### Name
ALTER SYSTEM ADD FOLLOWER
### Description
改语句是增加 FRONTEND 的 FOLLOWER 角色的节点,(仅管理员使用!)
语法:
```sql
ALTER SYSTEM ADD FOLLOWER "follower_host:edit_log_port"
```
说明:
1. host 可以是主机名或者ip地址
2. edit_log_port : edit_log_port 在其配置文件 fe.conf
### Example
1. 添加一个 FOLLOWER节点
```sql
ALTER SYSTEM ADD FOLLOWER "host_ip:9010"
```
### Keywords
ALTER, SYSTEM, ADD, FOLLOWER

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-ADD-OBSERVER
### Name
ALTER SYSTEM ADD OBSERVER
### Description
改语句是增加 FRONTEND 的 OBSERVER 角色的节点,(仅管理员使用!)
语法:
```sql
ALTER SYSTEM ADD OBSERVER "follower_host:edit_log_port"
```
说明:
1. host 可以是主机名或者ip地址
2. edit_log_port : edit_log_port 在其配置文件 fe.conf
### Example
1. 添加一个 OBSERVER 节点
```sql
ALTER SYSTEM ADD OBSERVER "host_ip:9010"
```
### Keywords
ALTER, SYSTEM, ADD, OBSERVER

View File

@ -26,10 +26,35 @@ under the License.
## ALTER-SYSTEM-DECOMMISSION-BACKEND
### Name
ALTER SYSTEM DECOMMISSION BACKEND
### Description
节点下线操作用于安全下线节点。该操作为异步操作。如果成功,节点最终会从元数据中删除。如果失败,则不会完成下线(仅管理员使用!)
语法:
```sql
ALTER SYSTEM DECOMMISSION BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
```
说明:
1. host 可以是主机名或者ip地址
2. heartbeat_port 为该节点的心跳端口
3. 节点下线操作用于安全下线节点。该操作为异步操作。如果成功,节点最终会从元数据中删除。如果失败,则不会完成下线。
4. 可以手动取消节点下线操作。详见 CANCEL DECOMMISSION
### Example
1. 下线两个节点
```sql
ALTER SYSTEM DECOMMISSION BACKEND "host1:port", "host2:port";
```
### Keywords
ALTER, SYSTEM, DECOMMISSION, BACKEND

View File

@ -26,10 +26,34 @@ under the License.
## ALTER-SYSTEM-DROP-BACKEND
### Name
ALTER SYSTEM DROP BACKEND
### Description
该语句用于删除 BACKEND 节点(仅管理员使用!)
语法:
```sql
ALTER SYSTEM DROP BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...]
```
说明:
1. host 可以是主机名或者ip地址
2. heartbeat_port 为该节点的心跳端口
3. 增加和删除节点为同步操作。这两种操作不考虑节点上已有的数据,节点直接从元数据中删除,请谨慎使用。
### Example
1. 删除两个节点
```sql
ALTER SYSTEM DROP BACKEND "host1:port", "host2:port";
```
### Keywords
ALTER, SYSTEM, DROP, BACKEND

View File

@ -0,0 +1,66 @@
---
{
"title": "ALTER-SYSTEM-DROP-BROKER",
"language": "zh-CN"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-DROP-BROKER
### Name
ALTER SYSTEM DROP BROKER
### Description
该语句是删除 BROKER 节点,(仅限管理员使用)
语法:
```sql
删除所有 Broker
ALTER SYSTEM DROP ALL BROKER broker_name
删除某一个 Broker 节点
ALTER SYSTEM DROP BROKER broker_name "host:port"[,"host:port"...];
```
### Example
1. 删除所有 Broker
```sql
ALTER SYSTEM DROP ALL BROKER broker_name
```
2. 删除某一个 Broker 节点
```sql
ALTER SYSTEM DROP BROKER broker_name "host:port"[,"host:port"...];
```
### Keywords
ALTER, SYSTEM, DROP, FOLLOWER
### Best Practice

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-DROP-FOLLOWER
### Name
ALTER SYSTEM DROP FOLLOWER
### Description
改语句是增加 FRONTEND 的 FOLLOWER 角色的节点,(仅管理员使用!)
语法:
```sql
ALTER SYSTEM DROP FOLLOWER "follower_host:edit_log_port"
```
说明:
1. host 可以是主机名或者ip地址
2. edit_log_port : edit_log_port 在其配置文件 fe.conf
### Example
1. 添加一个 FOLLOWER节点
```sql
ALTER SYSTEM DROP FOLLOWER "host_ip:9010"
```
### Keywords
ALTER, SYSTEM, DROP, FOLLOWER

View File

@ -26,10 +26,33 @@ under the License.
## ALTER-SYSTEM-DROP-OBSERVER
### Name
ALTER SYSTEM DROP OBSERVER
### Description
改语句是增加 FRONTEND 的 OBSERVER 角色的节点,(仅管理员使用!)
语法:
```sql
ALTER SYSTEM DROP OBSERVER "follower_host:edit_log_port"
```
说明:
1. host 可以是主机名或者ip地址
2. edit_log_port : edit_log_port 在其配置文件 fe.conf
### Example
1. 添加一个 FOLLOWER节点
```sql
ALTER SYSTEM DROP OBSERVER "host_ip:9010"
```
### Keywords
ALTER, SYSTEM, DROP, OBSERVER

View File

@ -0,0 +1,77 @@
---
{
"title": "ALTER-SYSTEM-MODIFY-BACKEND",
"language": "zh-CN"
}
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
## ALTER-SYSTEM-MODIFY-BACKEND
### Name
ALTER SYSTEM MKDIFY BACKEND
### Description
修改 BE 节点属性(仅管理员使用!)
语法:
```sql
ALTER SYSTEM MODIFY BACKEND "host:heartbeat_port" SET ("key" = "value"[, ...]);
```
说明:
1. host 可以是主机名或者ip地址
2. heartbeat_port 为该节点的心跳端口
3. 修改 BE 节点属性目前支持以下属性:
- tag.location:资源标签
- disable_query: 查询禁用属性
- disable_load: 导入禁用属性
### Example
1. 修改 BE 的资源标签
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("tag.location" = "group_a");
```
2. 修改 BE 的查询禁用属性
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("disable_query" = "true");
```
3. 修改 BE 的导入禁用属性
```sql
ALTER SYSTEM MODIFY BACKEND "host1:9050" SET ("disable_load" = "true");
```
### Keywords
ALTER, SYSTEM, ADD, BACKEND
### Best Practice

View File

@ -26,13 +26,31 @@ under the License.
## CANCEL-ALTER-SYSTEM
### Name
CANCEL DECOMMISSION
### Description
该语句用于撤销一个节点下线操作。(仅管理员使用!)
语法:
```sql
CANCEL DECOMMISSION BACKEND "host:heartbeat_port"[,"host:heartbeat_port"...];
```
### Example
1. 取消两个节点的下线操作:
```sql
CANCEL DECOMMISSION BACKEND "host1:port", "host2:port";
```
### Keywords
CANCEL, ALTER, SYSTEM
CANCEL, DECOMMISSION
### Best Practice