---
title: "启动集群 - OceanBase 数据库 V4.3.0 | OceanBase 文档中心"
description: "启动集群 本文档介绍如何启动集群。 调用说明 接口约束 obshell Server 会对该 API 进行安全校验，详细介绍可参见 API 混合加密 。 请求路径 POST /api/v1/ob/start 请求参数 参数 类型 必选 示例值 描述 scope Scope 是 { &quot;type&quot;: &quot;GLOBAL&quot; }…"
---
切换语言

- 中文站 - 简体中文
- International - English
- 日本站 - 日本語

文档反馈![](https://mdn.alipayobjects.com/huamei_22khvb/afts/img/A*P8CuR4UJ_FkAAAAAAAAAAAAADiGDAQ/original) OceanBase 数据库分布式版 - V 4.3.0

# 启动集群

更新时间：2026-04-10 11:58:35

[编辑](https://github.com/oceanbase/oceanbase-doc/edit/V4.3.0/zh-CN/700.reference/1500.Components-and-Tools/100.manage/100.obshell/400.obshell-api-reference/700.start-cluster.md)  

本文档介绍如何启动集群。

## 调用说明

### 接口约束

obshell Server 会对该 API 进行安全校验，详细介绍可参见 [API 混合加密](https://www.oceanbase.com/docs/common-oceanbase-database-cn-1000000000694620)。

### 请求路径

POST /api/v1/ob/start

### 请求参数

| 参数 | 类型 | 必选 | 示例值 | 描述 |
| --- | --- | --- | --- | --- |
| scope | Scope | 是 | {   "type": "GLOBAL"   } | 设置应用该配置的 OBServer 节点的范围。详细的内容介绍可参见下文 **Scope 信息的数据结构**。 |
| forcePassDag | []string | 否 | 无 | 指定前序启/停任务的 ID。仅在特殊情况下使用（当集群运维被一个或者多个前序运维任务锁住时，可以使用该参数将前序任务解锁）。 |

Scope 信息的数据结构:

| 参数 | 类型 | 必选 | 示例值 | 说明 |
| --- | --- | --- | --- | --- |
| type | string | 是 | "GLOBAL" | 设置配置的生效级别，可取值为 `GLOBAL`，`ZONE`，`SERVER`。 |
| target | []string | 否 | 示例值：["10.10.10.1:2886", "10.10.10.2:2886"] 或者 ["zone1","zone2"] | 当 `type` 为 `SERVER` 时，设置为 OBServer 节点的列表；当 `type` 为 `ZONE` 时，设置为 Zone 的列表；当 `type` 为 `GLOBAL` 时，无需设置。 |

### 返回结果

| 参数 | 类型 | 说明 |
| --- | --- | --- |
| successful | bool | 请求是否成功。 |
| timestamp | time.Time | 服务端完成请求的时间戳。 |
| duration | int | 服务端处理请求的时间（毫秒） |
| status | int | 符合 HTTP Status 规范的编码 |
| traceId | string | 请求的 Trace ID |
| data | DagDetailDTO | 详情参见下文 **DagDetailDTO 信息的数据结构**。 |
| error | ApiError | 请求产生的 Error，包含如下信息：   - `code`：错误码。 - `message`：错误详细信息。 - `subErrors`：子错误信息。 |

DagDetailDTO 信息的数据结构如下：

| 参数 | 类型 | 说明 |
| --- | --- | --- |
| id | string | DAG 通用 ID。 |
| dag_id | int | DAG id，是记录在 OceanBase 数据库中的主键。 |
| name | string | DAG 名称。 |
| stage | int | DAG 的当前执行阶段。 |
| max_stage | int | DAG 执行过程中的总阶段数。 |
| state | string | DAG 执行状态。 |
| operator | string | DAG 执行操作类型。 |
| start_time | time.Time | DAG 执行起始时间。 |
| end_time | time.Time | DAG 执行结束时间。 |
| additional_data | map[string]any | DAG 其他数据。 |
| nodes | []NodeDetailDTO | DAG 内的所有 Node 信息，详见 [获取 Node 的详细信息](https://www.oceanbase.com/docs/common-oceanbase-database-cn-1000000000694622)。 |

## 示例

### 请求示例

POST 10.10.10.1:2886/api/v1/ob/start

```json
{
    "scope": {
        "type": "GLOBAL"
    }
}

```

### 返回示例

```json
{
    "successful": true,
    "timestamp": "2024-01-10T11:24:44.515966754+08:00",
    "duration": 3,
    "status": 200,
    "traceId": "c697089607fac2f1",
    "data": {
        "id": "22130706433028869",
        "dag_id": 13,
        "name": "Start OB",
        "stage": 1,
        "max_stage": 6,
        "state": "READY",
        "operator": "RUN",
        "start_time": "2024-01-10T11:24:44.513664697+08:00",
        "end_time": "2024-01-10T11:24:44.513664697+08:00",
        "additional_data": null,
        "nodes": null
    }
}

```

## 相关文档

除通过命令行调用 API 接口外，还可以通过 SDK 方法调用 API。

- 通过 obshell-sdk-python 请求 API 方法的介绍可参见 [启动集群](https://www.oceanbase.com/docs/common-oceanbase-database-cn-1000000000904134)。
 - 通过 obshell-sdk-go 请求 API 方法的介绍可参见 [启动集群](https://www.oceanbase.com/docs/common-oceanbase-database-cn-1000000000904161)。

 上一篇 下一篇 ![有帮助](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*y6ocSqN8cqsAAAAAAAAAAAAAARQnAQ)![无帮助](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*BG9IQJyLHF8AAAAAAAAAAAAAARQnAQ)![反馈](https://gw.alipayobjects.com/mdn/ob_asset/afts/img/A*eTWdQKCRKHwAAAAAAAAAAAAAARQnAQ)[AI](https://www.oceanbase.com/obi) 咨询热线
