OceanBase logo

OceanBase

A unified distributed database ready for your transactional, analytical, and AI workloads.

DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Resources

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS

OceanBase Cloud

OceanBase Database

Tools

Connectors and Middleware

QUICK START

OceanBase Cloud

OceanBase Database

BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Company

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

International - English
中国站 - 简体中文
日本 - 日本語
Sign In
Start on Cloud

A unified distributed database ready for your transactional, analytical, and AI workloads.

DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS
OceanBase CloudOceanBase Database
ToolsConnectors and Middleware
QUICK START
OceanBase CloudOceanBase Database
BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

Start on Cloud
编组
All Products
    • Databases
    • iconOceanBase Database
    • iconOceanBase Cloud
    • iconOceanBase Tugraph
    • iconInteractive Tutorials
    • iconOceanBase Best Practices
    • Tools
    • iconOceanBase Cloud Platform
    • iconOceanBase Migration Service
    • iconOceanBase Developer Center
    • iconOceanBase Migration Assessment
    • iconOceanBase Admin Tool
    • iconOceanBase Loader and Dumper
    • iconOceanBase Deployer
    • iconKubernetes operator for OceanBase
    • iconOceanBase Diagnostic Tool
    • iconOceanBase Binlog Service
    • Connectors and Middleware
    • iconOceanBase Database Proxy
    • iconEmbedded SQL in C for OceanBase
    • iconOceanBase Call Interface
    • iconOceanBase Connector/C
    • iconOceanBase Connector/J
    • iconOceanBase Connector/ODBC
    • iconOceanBase Connector/NET
icon

Kubernetes operator for OceanBase

V2.3.1Community Edition

  • Overview
  • Quick start
  • Deploy
  • Upgrade
  • User guide
    • Cluster management
      • Manage clusters
      • Create a cluster
      • Zone management
        • Add zones to a cluster
        • Delete zones from a cluster
      • Server management
        • Add OBServer nodes to zones
        • Delete OBServer nodes from zones
      • Upgrade a cluster
      • Manage parameters
      • Update resources
      • Delete a cluster
    • Tenant management
      • Manage tenants
      • Create a tenant
      • Modify tenant
        • Manage resources
        • Manage replicas
        • Modify other parameters
      • Delete a tenant
      • Perform tenant O&M operations
    • High availability
      • High availability
      • Recover from node failure
      • Back up a tenant
      • Restore data from a backup
      • Physical standby tenant
      • Inter K8s cluster management
  • Configure
  • Appendix
    • Deploy OceanBase Database and web app in a Kubernetes cluster
    • FAQ
  • Changelog

Download PDF

Overview Quick start Deploy Upgrade Manage clusters Create a cluster Upgrade a cluster Manage parameters Update resources Delete a cluster Manage tenants Create a tenant Delete a tenant Perform tenant O&M operations High availability Recover from node failure Back up a tenant Restore data from a backup Physical standby tenant Inter K8s cluster management Configure Deploy OceanBase Database and web app in a Kubernetes cluster FAQ Changelog
OceanBase logo

The Unified Distributed Database for the AI Era.

Follow Us
Products
OceanBase CloudOceanBase EnterpriseOceanBase Community EditionOceanBase seekdb
Resources
DocsBlogLive DemosTraining & Certification
Company
About OceanBaseTrust CenterLegalPartnerContact Us
Follow Us

© OceanBase 2026. All rights reserved

Cloud Service AgreementPrivacy PolicySecurity
Contact Us
Document Feedback
  1. Documentation Center
  2. Kubernetes operator for OceanBase
  3. V2.3.1
iconKubernetes operator for OceanBase
V 2.3.1Community Edition
Community Edition
  • V 2.3.1
  • V 2.3.0
  • V 2.2.0
  • V 2.1.2
  • V 2.1.1
  • V 2.1.0

Quick start

Last Updated:2025-11-28 06:07:04  Updated
share
What is on this page
Prerequisites
Deploy ob-operator
Deploy an OceanBase cluster
What to do next

folded

share

This topic describes how to deploy ob-operator and an OceanBase cluster and use ob-operator to manage OceanBase Database.

Prerequisites

Before you start the deployment, make sure that the following conditions are met:

  • You have an available Kubernetes cluster, which has at least 2 CPU cores, 10 GB of memory, and 100 GB of storage space.
  • You have installed cert-manager. For more information about how to install cert-manager, see the installation document.
  • You have installed local-path-provisioner and confirmed that the specified destination has sufficient storage space. For more information about how to install local-path-provisioner, see the documentation on GitHub.

Deploy ob-operator

Run the following command to deploy ob-operator in the Kubernetes cluster:

  • Deploy the stable version of ob-operator

    kubectl apply -f https://raw.githubusercontent.com/oceanbase/ob-operator/stable/deploy/operator.yaml
    
  • Deploy the developing version of ob-operator

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

Run the following command to verify that ob-operator is deployed:

kubectl get pod -n oceanbase-system

The expected output is as follows:

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

Deploy an OceanBase cluster

Perform the following steps to deploy an OceanBase cluster in the Kubernetes cluster:

  1. Create secrets Before you create an OceanBase cluster, you must create secrets required for specific users. Run the following commands to create secrets:

    kubectl create secret generic root-password --from-literal=password='root_password'
    kubectl create secret generic proxyro-password --from-literal=password='proxyro_password'
    kubectl create secret generic monitor-password --from-literal=password='monitor_password'
    kubectl create secret generic operator-password --from-literal=password='operator_password'
    
  2. Deploy an OceanBase cluster Run the following command to deploy an OceanBase cluster in the Kubernetes cluster:

    kubectl apply -f https://raw.githubusercontent.com/oceanbase/ob-operator/stable/example/quickstart/obcluster.yaml
    

    In general, it takes about 2 minutes to create a cluster. Run the following command to check the cluster status:

    kubectl get obclusters.oceanbase.oceanbase.com test
    

    The expected output is as follows:

    NAME   STATUS    AGE
    test   running   6m2s
    
  3. Connect to the OceanBase cluster Perform the following steps to connect to the created OceanBase cluster:

    # Run the following command to obtain the IP address and name of the pod for the server where the OceanBase cluster is deployed.
    # The pod name is in the {cluster_name}-{cluster_id}-{zone}-uuid format.
    kubectl get pods -o wide
    # Run the following command to connect to the cluster.
    mysql -h{POD_IP} -P2881 -uroot -p'root_password' oceanbase -A -c
    

If you have any questions or need help, contact OceanBase Technical Support.

What to do next

This topic describes how to deploy ob-operator and an OceanBase cluster. You can use the method to quickly set up the environment. For more information about the deployment and O&M of clusters in a production environment, see Manage clusters.

After you create a cluster, you need to create a business tenant. For more information about tenant management, see Manage OceanBase Database tenants.

Previous topic

Overview
Last

Next topic

Deploy
Next
What is on this page
Prerequisites
Deploy ob-operator
Deploy an OceanBase cluster
What to do next