doc/TD-32681-drop-dnode-add-option

This commit is contained in:
dmchen 2024-10-25 09:51:57 +00:00
parent dd913a211d
commit c404086a5a
2 changed files with 6 additions and 18 deletions

View File

@ -27,20 +27,14 @@ The preceding SQL command shows all dnodes in the cluster with the ID, endpoint,
## Delete a DNODE ## Delete a DNODE
```sql ```sql
DROP DNODE dnode_id DROP DNODE dnode_id [force] [unsafe]
``` ```
Note that deleting a dnode does not stop its process. You must stop the process after the dnode is deleted. Note that deleting a dnode does not stop its process. You must stop the process after the dnode is deleted.
```sql Only online node is allowed to be deleted. Drop is executed with force option if the offline node need to be deleted.
DROP DNODE dnode_id force
```
Only online node is allowed to be deleted. Drop is executed forcely if the offline node need to be deleted.
```sql Drop is executed with unsafe option if the node with single replica is offline, and the data on it is not able to be restored.
DROP DNODE dnode_id unsafe
```
Drop is executed unsafely if the node with single replica is offline, and the data on it is not able to be restored.
## Modify Dnode Configuration ## Modify Dnode Configuration

View File

@ -27,20 +27,14 @@ SHOW DNODES;
## 删除数据节点 ## 删除数据节点
```sql ```sql
DROP DNODE dnode_id DROP DNODE dnode_id [force] [unsafe]
``` ```
注意删除 dnode 不等于停止相应的进程。实际中推荐先将一个 dnode 删除之后再停止其所对应的进程。 注意删除 dnode 不等于停止相应的进程。实际中推荐先将一个 dnode 删除之后再停止其所对应的进程。
```sql 只有在线节点可以被删除。如果要强制删除离线节点,需要执行强制删除操作, 即指定force选项。
DROP DNODE dnode_id force
```
只有在线节点可以被删除。如果要强制删除离线节点,需要执行强制删除操作。
```sql 当节点上存在单副本并且节点处于离线如果要强制删除该节点需要执行非安全删除即制定unsafe并且数据不可再恢复。
DROP DNODE dnode_id unsafe
```
当节点上存在单副本,并且节点处于离线,如果要强制删除该节点,需要执行非安全删除,并且数据不可再恢复。
## 修改数据节点配置 ## 修改数据节点配置