---
title: "ob-operator 部署 | OceanBase 文档中心"
description: ob-operator 部署 本文介绍如何部署 ob-operator。 前提条件 ob-operator 依赖 cert-manager。在部署 ob-operator 之前，确保您已安装 cert-manager。cert-manager 的安装方法请参考对应的 安装文档 。 使用 Helm 部署 ob-oper…
---
切换语言

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

文档反馈![](https://mdn.alipayobjects.com/huamei_22khvb/afts/img/A*_Ef7QIYUi3gAAAAAAAAAAAAADiGDAQ/original) ob-operatorV 2.3.4 社区版

# ob-operator 部署

更新时间：2026-07-05 13:09:09

[编辑](https://github.com/oceanbase/ob-operator-doc/edit/V2.3.4/zh-CN/300.deploy-ob-operator.md)  

本文介绍如何部署 ob-operator。

## 前提条件

ob-operator 依赖 cert-manager。在部署 ob-operator 之前，确保您已安装 cert-manager。cert-manager 的安装方法请参考对应的 [安装文档](https://cert-manager.io/docs/installation/)。

## 使用 Helm 部署

ob-operator 支持使用 Helm 部署。在使用 Helm 命令部署 ob-operator 之前，确保您已安装 [Helm](https://github.com/helm/helm)。Helm 安装完成后，使用以下命令部署 ob-operator：

```shell
helm repo add ob-operator https://oceanbase.github.io/ob-operator/
helm install ob-operator ob-operator/ob-operator --namespace=oceanbase-system --create-namespace

```

其中，`--namespace` 用于设置命名空间，可根据需要自定义，建议使用 `oceanbase-system`。

## 使用配置文件部署

您可以直接使用配置文件部署 ob-operator。根据您的需求选择稳定版本或开发版本的配置文件。

- 稳定版本

  ```shell
  kubectl apply -f https://raw.githubusercontent.com/oceanbase/ob-operator/stable/deploy/operator.yaml

  ```
 - 开发版本

  ```shell
  kubectl apply -f https://raw.githubusercontent.com/oceanbase/ob-operator/master/deploy/operator.yaml

  ```

一般建议使用稳定版本的配置文件，如果您想使用开发中的版本，可以选择使用开发的配置文件。

## 查看部署结果

部署成功后，您可以通过以下命令查看 CRD 的定义，以确认部署是否成功：

```shell
kubectl get crds

```

如果输出与以下示例相似，则表示部署成功：

```shell
NAME                                            CREATED AT
obparameters.oceanbase.oceanbase.com             2023-11-12T08:06:58Z
observers.oceanbase.oceanbase.com                2023-11-12T08:06:58Z
obtenantbackups.oceanbase.oceanbase.com          2023-11-12T08:06:58Z
obtenantrestores.oceanbase.oceanbase.com         2023-11-12T08:06:58Z
obzones.oceanbase.oceanbase.com                  2023-11-12T08:06:58Z
obtenants.oceanbase.oceanbase.com                2023-11-12T08:06:58Z
obtenantoperations.oceanbase.oceanbase.com       2023-11-12T08:06:58Z
obclusters.oceanbase.oceanbase.com               2023-11-12T08:06:58Z
obtenantbackuppolicies.oceanbase.oceanbase.com   2023-11-12T08:06:58Z

```

通过如下命令确认 ob-operator 部署成功。

```shell
kubectl get pods -n oceanbase-system

```

返回结果如下，当看到所有容器都 ready 时并且 status 为 Running， 则表示部署成功。

```shell
NAME                                            READY   STATUS    RESTARTS   AGE
oceanbase-controller-manager-86cfc8f7bf-4hfnj   2/2     Running   0          1m

```

 上一篇 下一篇 ![有帮助](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) 咨询热线
