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

OceanBase Database Proxy

V4.3.3

  • What is ODP?
  • Installation and deployment
    • Overview
    • Deploy ODP by using obd
    • Deploy ODP by using OCP
    • Deploy ODP by using the CLI
    • Deployment modes
  • Basic operations
  • Configuration parameter
    • View and modify parameters
    • Parameter summary
    • Global parameters
      • automatic_match_work_thread
      • block_thread_num
      • cache_cleaner_clean_interval
      • check_tenant_locality_change
      • client_max_connections
      • client_max_memory_size
      • client_session_id_version
      • client_sock_option_flag_out
      • client_tcp_keepcnt
      • client_tcp_keepidle
      • client_tcp_keepintvl
      • client_tcp_user_timeout
      • cluster_count_high_water_mark
      • cluster_expire_time
      • config_server_refresh_interval
      • congestion_fail_window
      • congestion_failure_threshold
      • congestion_retry_interval
      • connection_diagnosis_option
      • connect_observer_max_retries
      • current_local_config_version
      • default_buffer_water_mark
      • default_inactivity_timeout
      • delay_exit_time
      • delay_update_entry_interval
      • detect_server_timeout
      • digest_sql_length
      • enable_abort_conn_info
      • enable_async_log
      • enable_async_pull_location_cache
      • enable_bad_route_reject
      • enable_binlog_service
      • enable_cached_server
      • enable_causal_order_read
      • enable_client_connection_lru_disconnect
      • enable_client_ip_checkout
      • enable_cluster_checkout
      • enable_compression_protocol
      • enable_congestion
      • enable_connection_diagnosis
      • enable_cpu_isolate
      • enable_cpu_topology
      • enable_extra_prometheus_metric
      • enable_flow_control
      • enable_full_link_trace
      • enable_full_username
      • enable_get_rslist_remote
      • enable_global_ps_cache
      • enable_index_route
      • enable_monitor_stat
      • enable_ob_protocol_v2
      • enable_ob_protocol_v2_with_client
      • enable_obproxy_rpc_service
      • enable_partition_table_route
      • enable_performance_mode
      • enable_pl_route
      • enable_primary_zone
      • enable_prometheus
      • enable_proxy_scramble
      • enable_qa_mode
      • enable_qos
      • enable_report_session_stats
      • enable_reroute
      • enable_sequence_prefetch
      • enable_sharding
      • enable_single_leader_node_routing
      • enable_standby
      • enable_stat
      • enable_strict_kernel_release
      • enable_strict_stat_time
      • enable_sync_all_stats
      • enable_syslog_file_compress
      • enable_syslog_wf
      • enable_trace
      • enable_trace_stats
      • enable_trans_detail_stats
      • enable_transaction_internal_routing
      • enable_xa_route
      • fetch_proxy_bin_random_time
      • fetch_proxy_bin_timeout
      • flow_consumer_reenable_threshold
      • flow_event_queue_threshold
      • flow_high_water_mark
      • flow_low_water_mark
      • grpc_client_num
      • grpc_thread_num
      • hot_upgrade_exit_timeout
      • hot_upgrade_failure_retries
      • hot_upgrade_rollback_timeout
      • idc_list_refresh_interval
      • ignore_local_config
      • internal_cmd_mem_limited
      • ip_listen_mode
      • ldg_info_refresh_interval
      • listen_port
      • local_bound_ip
      • local_bound_ipv6_ip
      • log_cleanup_interval
      • log_dir_size_threshold
      • log_file_percentage
      • long_async_task_timeout
      • max_log_file_size
      • max_syslog_file_count
      • max_syslog_file_time
      • mem_leak_check_class_name
      • mem_leak_check_mod_name
      • metadb_server_state_refresh_interval
      • min_congested_connect_timeout
      • min_keep_congestion_interval
      • monitor_cost_ms_unit
      • monitor_item_limit
      • monitor_item_max_idle_period
      • monitor_log_level
      • monitor_stat_dump_interval
      • monitor_stat_high_threshold
      • monitor_stat_low_threshold
      • monitor_stat_middle_threshold
      • need_convert_vip_to_tname
      • net_accept_threads
      • net_config_poll_timeout
      • normal_pl_update_threshold
      • obproxy_config_server_url
      • obproxy_sys_password
      • partition_location_expire_relative_time
      • prometheus_cost_ms_unit
      • prometheus_listen_port
      • prometheus_sync_interval
      • protocol_diagnosis_level
      • proxy_hot_upgrade_check_interval
      • proxy_id
      • proxy_info_check_interval
      • proxy_local_cmd
      • proxy_mem_limited
      • qa_mode_mock_public_cloud_slb_addr
      • qos_stat_clean_interval
      • qos_stat_item_limit
      • refresh_idc_list
      • refresh_json_config
      • refresh_rslist
      • request_buffer_length
      • rootservice_list
      • routing_cache_mem_limited
      • rpc_async_task_thread_num
      • rpc_enable_congestion
      • rpc_enable_direct_expire_route_entry
      • rpc_enable_global_index
      • rpc_enable_force_srv_black_list
      • rpc_enable_parallel_handler
      • rpc_enable_reroute
      • rpc_enable_retry_request_info_log
      • rpc_force_srv_black_list
      • rpc_listen_port
      • rpc_max_request_batch_size
      • rpc_max_response_batch_size
      • rpc_net_timeout_base
      • rpc_max_server_table_entry_num
      • rpc_redis_operation_timeout
      • rpc_redis_default_database_name
      • rpc_period_task_interval
      • rpc_redis_default_user_name
      • rpc_request_timeout
      • rpc_server_entry_expire_time
      • rpc_request_timeout_delta
      • rpc_server_net_invalid_time_us
      • rpc_server_net_handler_expire_time
      • rpc_server_net_max_pending_request
      • rpc_srv_session_pool_inactive_timeout
      • rpc_service_mode
      • rpc_sub_request_isolation_mode
      • rpc_support_key_partition_shard_request
      • rpc_sub_request_weight
      • sequence_entry_expire_time
      • sequence_fail_retry_count
      • sequence_prefetch_threshold
      • server_detect_fail_threshold
      • server_detect_mode
      • server_detect_refresh_interval
      • server_routing_mode
      • server_state_refresh_interval
      • server_tcp_init_cwnd
      • server_tcp_keepcnt
      • server_tcp_keepidle
      • server_tcp_keepintvl
      • server_tcp_user_timeout
      • shard_scan_thread_num
      • short_async_task_timeout
      • skip_proxy_sys_private_check
      • skip_proxyro_check
      • slow_proxy_process_time_threshold
      • slow_transaction_time_threshold
      • sock_option_flag_out
      • sock_packet_mark_out
      • sock_packet_tos_out
      • sock_recv_buffer_size_out
      • sock_send_buffer_size_out
      • sql_table_cache_expire_relative_time
      • sql_table_cache_mem_limited
      • sqlaudit_mem_limited
      • stack_size
      • stat_dump_interval
      • stat_table_sync_interval
      • syslog_io_bandwidth_limit
      • syslog_level
      • task_thread_num
      • tenant_location_valid_time
      • tunnel_request_size_threshold
      • username_separator
      • work_thread_num
      • xflush_log_level
    • Multi-level parameters
      • binlog_service_ip
      • compression_algorithm
      • enable_check_cluster_name
      • enable_client_ssl
      • enable_cloud_full_username
      • enable_read_write_split
      • enable_rpc_throttle
      • enable_server_ssl
      • enable_standby_read_write_split
      • enable_transaction_split
      • enable_weak_reroute
      • mysql_version
      • ob_max_read_stale_time
      • obproxy_force_parallel_query_dop
      • obproxy_read_consistency
      • obproxy_read_only
      • observer_query_timeout_delta
      • observer_sys_password
      • observer_sys_password1
      • proxy_idc_name
      • proxy_primary_zone_name
      • proxy_route_policy
      • proxy_tenant_name
      • query_digest_time_threshold
      • read_stale_retry_interval
      • rootservice_cluster_name
      • route_diagnosis_level
      • rpc_request_throttle_waiting_time
      • rpc_throttle_limit_qps_qa
      • route_target_replica_type
      • rpc_throttle_trigger_percentage
      • slow_query_time_threshold
      • sql_firewall_config
      • ssl_attributes
      • target_db_server
      • weakread_weight_zone
  • Connection management
    • Principles
    • Session status synchronization
    • Configure a globally unique client session ID
    • Client session
    • Server session
    • Network connection
  • Data routing
    • Factors affecting data routing
    • ODP routing
    • Intra-tenant routing
      • Overview
      • IP address-based routing
      • Partitioned table-based routing for strong-consistency reads
      • Global index table-based routing for strong-consistency reads
      • Replicated table-based routing for strong-consistency reads
      • Primary zone-based routing for strong-consistency reads
      • Strategy-based routing
      • Distributed transaction routing
      • Rerouting
      • Forcible routing
      • Weight-based load-balanced routing
    • Automatic routing to the primary/standby tenants
    • Read/Write separation
    • Follower latency threshold
    • Function partition key routing
      • Overview
      • String functions
      • Numeric calculation functions
      • Date calculation functions
      • FAQ
    • Character set-based routing
    • Partitioning key types supported for routing by ODP
  • Logs
    • Overview
    • obproxy_diagnosis.log
    • obproxy_digest.log
    • obproxy_error.log
    • obproxy_slow.log
    • obproxy_stat.log
    • obproxy.log
  • Commands
    • Overview
    • Dedicated ODP commands
      • ALTER
      • KILL
      • ping
      • SHOW
        • SHOW
        • SHOW PROXYPS
    • Compatible MySQL commands
      • BINLOG
      • KILL
      • SHOW PROCESSLIST
      • SHOW RELAYLOG EVENTS
      • SHOW SLAVE HOSTS
  • High availability mechanism
    • Overview
    • High availability of ODP services
    • High availability of OceanBase Database
    • High availability testing
  • OBKV
    • RPC service port
    • Throttling
    • OBKV-Redis
  • Security and protocols
  • Operation and maintenance
    • Troubleshooting logic
    • Performance analysis
    • Show Trace
    • Routing diagnostics
      • Overview
      • Obtain diagnostic information
      • Diagnostic point troubleshooting
        • Overview
        • SQL_PARSE
        • ROUTE_INFO
        • LOCATION_CACHE_LOOKUP
        • ROUTINE_ENTRY_LOOKUP_DONE
        • FETCH_TABLE_RELATED_DATA
        • TABLE_ENTRY_LOOKUP_DONE
        • EXPR_PARSE
        • CALC_ROWID
        • RESOLVE_TOKEN
        • RESOLVE_EXPR
        • CALC_PARTITION_ID
        • PARTITION_ID_CALC_DONE
        • PARTITION_ENTRY_LOOKUP_DONE
        • ROUTE_POLICY
        • CONGESTION_CONTROL
        • RETRY
        • HANDLE_RESPONSE
      • Examples
    • Memory leak diagnostics
    • Connection diagnostics
    • Prometheus monitoring
    • SQL firewall
  • Release Notes
    • Versioning rules
    • Enterprise Edition
      • V4.3
        • ODP Enterprise Edition V4.3.3
        • ODP Enterprise Edition V4.3.2
        • ODP Enterprise Edition V4.3.1
        • ODP Enterprise Edition V4.3.0
      • V4.2
        • ODP Enterprise Edition V4.2.3
        • ODP Enterprise Edition V4.2.2
        • ODP Enterprise Edition V4.2.1
      • V4.1
        • ODP Enterprise Edition V4.1.0
      • V4.0
        • ODP Enterprise Edition V4.0.0
      • V3.2
        • ODP Enterprise Edition V3.2.11
        • ODP Enterprise Edition V3.2.3.5
    • Community Edition
      • V4.3
        • ODP Community Edition V4.3.3
        • ODP Community Edition V4.3.2
        • ODP Community Edition V4.3.1
      • V4.2
        • ODP Community Edition V4.2.3
        • ODP Community Edition V4.2.1
        • ODP Community Edition V4.2.0
      • V4.1
        • ODP Community Edition V4.1.0
      • V4.0
        • ODP Community Edition V4.0.0

Download PDF

What is ODP? Overview Deploy ODP by using obd Deploy ODP by using OCP Deploy ODP by using the CLI Deployment modes Basic operations View and modify parameters Parameter summary automatic_match_work_thread block_thread_num cache_cleaner_clean_interval check_tenant_locality_change client_max_connections client_max_memory_size client_session_id_version client_sock_option_flag_out client_tcp_keepcnt client_tcp_keepidle client_tcp_keepintvl client_tcp_user_timeout cluster_count_high_water_mark cluster_expire_time config_server_refresh_interval congestion_fail_window congestion_failure_threshold congestion_retry_interval connection_diagnosis_option connect_observer_max_retries current_local_config_version default_buffer_water_mark default_inactivity_timeout delay_exit_time delay_update_entry_interval detect_server_timeout digest_sql_length enable_abort_conn_info enable_async_log enable_async_pull_location_cache enable_bad_route_reject enable_binlog_service enable_cached_server enable_causal_order_read enable_client_connection_lru_disconnect enable_client_ip_checkout enable_cluster_checkout enable_compression_protocol enable_congestion enable_connection_diagnosis enable_cpu_isolate enable_cpu_topology enable_extra_prometheus_metric enable_flow_control enable_full_link_trace enable_full_username enable_get_rslist_remote enable_global_ps_cache enable_index_route enable_monitor_stat enable_ob_protocol_v2 enable_ob_protocol_v2_with_client enable_obproxy_rpc_service enable_partition_table_route enable_performance_mode enable_pl_route enable_primary_zone enable_prometheus enable_proxy_scramble enable_qa_mode enable_qos enable_report_session_stats enable_reroute enable_sequence_prefetch enable_sharding enable_single_leader_node_routing enable_standby enable_stat enable_strict_kernel_release enable_strict_stat_time enable_sync_all_stats enable_syslog_file_compress enable_syslog_wf enable_trace enable_trace_stats enable_trans_detail_stats enable_transaction_internal_routing enable_xa_route fetch_proxy_bin_random_time fetch_proxy_bin_timeout flow_consumer_reenable_threshold flow_event_queue_threshold flow_high_water_mark flow_low_water_mark grpc_client_num grpc_thread_num hot_upgrade_exit_timeout hot_upgrade_failure_retries hot_upgrade_rollback_timeout idc_list_refresh_interval ignore_local_config
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. OceanBase Database Proxy
  3. V4.3.3
iconOceanBase Database Proxy
V 4.3.3
  • V 4.3.6
  • V 4.3.4
  • V 4.3.3
  • V 4.3.2
  • V 4.3.1
  • V 4.3.0
  • V 4.2.3
  • V 4.2.2
  • V 4.2.0 and earlier

Deploy ODP by using obd

Last Updated:2026-04-14 01:41:30  Updated
share
What is on this page
Prerequisites
Choose a suitable version
Procedure
Step 1: Download and install obd
Step 2: Modify the configuration file
Step 3: Deploy ODP
Step 4: Perform a check after the installation
FAQ
Startup failed
Failed to connect to OceanBase Database

folded

share

This topic describes how to deploy OceanBase Database Proxy (ODP) by using OceanBase Deployer (obd). To do so, perform the following steps:

  1. Prepare the installation environment

  2. Choose a suitable version

  3. Install ODP by using obd

  4. Perform a check after the installation

You can also deploy ODP in the following ways:

  • Deploy ODP by using OceanBase Cloud Platform (OCP). For more information, see Deploy ODP by using OCP.

  • Deploy ODP by using the CLI. For more information, see Deploy ODP by using the CLI.

Prerequisites

  • Architecture: x86_64 or ARM.

  • Operating system: Linux Red Hat (x86_64) of version 5, 6, 7, or later.

  • CPU: ODP occupies about 70% of the resources of a CPU core during operation.

  • Memory: ODP occupies about 100 MB of memory during operation.

  • Disk space: The disk space is determined by your data size. We recommend that you use a disk that has 10 GB or more of space.

  • OceanBase cluster: At least one OceanBase cluster is required. For more information, see Overview.

  • (Optional) obconfigserver: If the obconfigserver is deployed, you can configure obproxy_config_server_url to start ODP. In this case, ODP can serve as a proxy for all clusters registered with obconfigserver.

Choose a suitable version

If you install ODP for learning purposes, install the latest version. For a production environment, we recommend that you check the new features and fixed issues of each version.

ODP is now available as an open-source project. You can find the OBProxy project under the open-source OceanBase Database project. Click Releases to view the details of each version. Each version of ODP has been tested in terms of features, stress handling, and performance, and can be used with guaranteed performance.

Procedure

Notice

  • The following describes the deployment of OceanBase Database on an x86-based CentOS Linux 7.9 platform by using obd V2.10.0. The procedure may be different for other obd versions or on other OS platforms.

  • Before you deploy ODP, we recommend that you switch to a non-root user for data security.

Step 1: Download and install obd

Choose a proper method to download and install obd. If your server has access to the Internet and allows you to add a third-party YUM repository as the software source, you can run the following commands to install obd from the official software source of OceanBase:

sudo yum install -y yum-utils
sudo yum-config-manager --add-repo https://mirrors.aliyun.com/oceanbase/OceanBase.repo
sudo yum install -y ob-deploy
source /etc/profile.d/obd.sh

If your server does have access to the Internet, download the obd installation package from OceanBase Download Center by using another server, and then transfer the installation package to your server for installation. For more information, see Install and configure obd.

Step 2: Modify the configuration file

After obd is installed, you can view the configuration files provided by obd in the /usr/obd/example/ directory and select an appropriate configuration file as needed. The configuration file used in this example is named obproxy-only-example.yaml and located in the example/obproxy/ directory.

obproxy-ce:
  version: 4.3.0.0
  servers:
    - 10.10.10.1
  global:
    listen_port: 2883 # External port. The default value is 2883.
    prometheus_listen_port: 2884 # The Prometheus port. The default value is 2884.
    rpc_listen_port: 2885
    enable_obproxy_rpc_service: true
    home_path: /home/admin/obproxy
    obproxy_config_server_url: http://10.10.10.1:8080/services?Action=GetObProxyConfig
    # rs_list: 10.10.10.1:2881;10.10.10.2:2881;10.10.10.3:2881
    enable_cluster_checkout: false
    skip_proxy_sys_private_check: true
    enable_strict_kernel_release: false
    cluster_name: obcluster
    client_session_id_version: 2 #This parameter is used to specify whether to use the new logic to generate the client session ID. The parameter type is integer. The value range is [1, 2] and the default value is 2 (use the new logic).
    proxy_id: 5 #This parameter is used to set the ID for an ODP. The parameter type is integer. The default value is 0 and the value range is [0, 8191].
    obproxy_sys_password: ****** # obproxy sys user password, can be empty. When a depends exists, obd gets this value from the oceanbase-ce of the depends.
    observer_sys_password: ****** # proxyro user pasword, consistent with oceanbase-ce's proxyro_password, can be empty. When a depends exists, obd gets this value
Parameter Required? Default value Description
version No Latest version The version of ODP to be deployed. If this parameter is not specified, obd deploys the latest version of ODP by default.
servers Yes None The servers where ODP is to be deployed. Specify each server in the format of - name: server identifier (line feed) ip: server IP address. You can specify multiple servers. The server identifiers must be unique.
You can specify unique server IP addresses in the format of - <ip> (line feed) - <ip>, where - <ip> is equivalent to - name: server IP address (line feed) ip: server IP address.
listen_port Yes 2883 The listening port of ODP.
prometheus_listen_port Yes 2884 The Prometheus listening port of ODP.
rpc_listen_port No 2885 The remote procedure call (RPC) service listening port of ODP.

Note

This parameter is available in obd V2.10.0 and later. It takes effect when the value of the enable_obproxy_rpc_service parameter is true.

enable_obproxy_rpc_service No true Specifies whether to enable the RPC service of ODP. The default value true indicates to enable the RPC service. The value false indicates to disable the RPC service. When the value of this parameter is false, the rpc_listen_port parameter does not take effect.

Note

  • This parameter is available in obd V2.10.0 and later.

  • If this parameter is not specified, it is automatically set to false after you upgrade ODP.
home_path Yes None The installation path of ODP.
obproxy_config_server_url No None The URL of the config server. After this parameter is specified, ODP can serve as a proxy for all clusters registered with the config server. If the config server is not deployed, you can also specify the rs_list parameter.
rs_list No None The OBServer node list of the OceanBase cluster, in the ip:mysql_port;ip:mysql_port format. If ODP is configured by using the RootService list, ODP can serve as a proxy only for the configured cluster.

Notice

  • You need to only configure either rs_list or obproxy_config_server_url.

  • If the RootService list in the OceanBase cluster changes after you start ODP by using the RootService list specified by rs_list, you need to manually modify the setting of the rs_list parameter and restart ODP for the change to take effect.
enable_cluster_checkout No true Specifies whether to verify the cluster name. If you set the value to true, ODP sends the cluster name to the OBServer node for verification during login.
enable_strict_kernel_release Yes false Specifies whether to verify the kernel of the operating system. The value true indicates that ODP supports only Linux Red Hat of version 5, 6, or 7. The value false indicates that the Linux kernel version is not verified. In this case, ODP may be unstable.
cluster_name No None The name of the OceanBase cluster for which ODP can serve as a proxy. If a dependency exists, obd obtains this value from the oceanbase-ce dependency.
client_session_id_version No 2 Specifies whether to use the new logic for generating client session IDs. Valid values are 1 and 2. The value 2 specifies to use the new logic for generating client session IDs.

Note

You can set the client_session_id_version parameter in the configuration file starting from obd V2.7.0.

proxy_id No 0 The ID of ODP. It ensures that client session IDs generated by different ODP nodes do not conflict. The value range of proxy_id varies based on the value of client_session_id_version.
  • When client_session_id_version is set to 1, the value range of proxy_id is [0, 255].
  • When client_session_id_version is set to 2, the value range of proxy_id is [0, 8191].

Note

You can set the proxy_id parameter in the configuration file starting from obd V2.7.0.

obproxy_sys_password No
  • Empty in versions earlier than obd V2.1.0
  • Random string in obd V2.1.0 and later
The password of the ODP administrator account (root@proxysys). If you do not specify this parameter in obd V2.1.0 or later, a random string is automatically generated. After deployment, you can run the obd cluster edit-config command to view the password in the configuration file.
observer_sys_password No The default value is the same as that of proxyro_password if OceanBase Database is deployed at the same time. If ODP is independently deployed, the default value varies based on the obd version as follows:
  • Empty in versions earlier than obd V2.1.0
  • Random string in obd V2.1.0 and later
The password of the account (proxyro@sys) used by ODP to connect to the OceanBase cluster. This password must be the same as the value of proxyro_password configured in OceanBase Database. Otherwise, you cannot connect to the OceanBase cluster by using ODP.

Step 3: Deploy ODP

If your server has access to the Internet, perform steps 4 and 5 directly. If your server does not have access to the Internet, download the ODP installation package from the Releases page on GitHub or OceanBase Download Center, and then copy the installation package to the local image repository as follows.

Note

For more information about the obd commands used in this step, see Cluster commands.

  1. Run the following command to disable the remote image repository:

    obd mirror disable <mirror repo name>
    

    The mirror repo name parameter specifies the name of the image repository to be disabled. If you set this parameter to remote, all remote image repositories are disabled.

  2. Run the following command to copy the ODP installation package to the local image repository:

    obd mirror clone <path> [-f]
    

    The path parameter specifies the path of the RPM package. The -f option indicates --force, which is optional and is disabled by default. When this option is enabled, if an image already exists, the image is forcibly overwritten.

  3. Run the following command to get the list of RPM packages in the local image repository:

    obd mirror list local
    
  4. Run the following command to deploy ODP:

    obd cluster deploy <deploy_name> -c <deploy_config_path>
    

    In the preceding command, the deploy_name parameter specifies the cluster name, which can be understood as the alias of the configuration file. deploy_config_path specifies the path of the configuration file.

    Note

    During online installation, after you run the obd cluster deploy command, obd checks whether the ODP installation package exists in the local image repository. If no, obd automatically obtains the installation package from the YUM repository.

  5. Run the following command to start ODP:

    obd cluster start <deploy_name> 
    

Step 4: Perform a check after the installation

  1. Run the following command to view the deployment result:

    obd cluster display <deploy_name>
    
    # Examples
    [admin@test ~]$ obd cluster display obtest
    Get local repositories and plugins ok
    Open ssh connection ok
    Cluster status check ok
    Connect to observer ok
    Wait for observer init ok
    +----------------------------------------------+
    |                 observer                     |
    +------------+---------+------+-------+--------+
    | ip         | version | port | zone  | status |
    +------------+---------+------+-------+--------+
    | 10.10.10.2 | 4.3.0.0 | 2881 | zone1 | ACTIVE |
    | 10.10.10.3 | 4.3.0.0 | 2881 | zone2 | ACTIVE |
    | 10.10.10.4 | 4.3.0.0 | 2881 | zone3 | ACTIVE |
    +------------+---------+------+-------+--------+
    obclient -h10.10.10.2 -P2881 -uroot -p****** -Doceanbase
    
    Connect to obproxy ok
    +----------------------------------------------+
    |                 obproxy                      |
    +------------+------+-----------------+--------+
    | ip         | port | prometheus_port | status |
    +------------+------+-----------------+--------+
    | 10.10.10.1 | 2883 | 2884            | active |
    +------------+------+-----------------+--------+
    obclient -h10.10.10.1 -P2883 -uroot -p****** -Doceanbase
    

    The ODP information is returned. 2883 in the port column indicates that port 2883 provides the SQL service. This port is required in the JDBC URL.

  2. After you check the status by using the obd cluster display command, you can log in to the server that hosts the obproxy process and run the ps -ef | grep obproxy command to view the process information.

    [admin@test ~]# ps -ef | grep obproxy | grep -v grep
    admin     6868     1  0 Nov12 ?        00:02:09 bash /home/admin/obproxy/obproxyd.sh /home/admin/obproxy 10.10.10.1 2883 daemon
    admin     6901     1  0 Nov12 ?        00:44:11 /home/admin/obproxy/bin/obproxy --listen_port 2883
    

    You can find the obproxyd.sh and obproxy processes in the return information of the preceding example. obproxy is the name of the ODP process, and obproxyd.sh is the daemon script of ODP. The obproxyd.sh process is responsible for starting the obproxy process and performs health check on the obproxy process. If the obproxy process does not exist, obproxyd.sh proactively pulls up the process.

FAQ

Startup failed

In a Linux system, ODP uses the enable_strict_kernel_release parameter to specify whether to check the operating system version. If the operating system fails the check, the startup fails. A sample key log is as follows:

[2021-10-13 10:38:17.235062] WARN [PROXY] get_kernel_release_by_uname (ob_config_server_processor.cpp:1039) [2060][Y0-0] [lt=14] [dc=0] unknown uname release(uinfo.release="4.18.0-80.el8.x86_64", ret=-4016)

You can run the uname command to view kernel information. This option supports only the EL series and AliOS series. The check strategies are conservative, and false errors may be reported. If you encounter the preceding issue in other Linux systems, you can disable the parameter to solve the problem.

Failed to connect to OceanBase Database

ODP establishes a connection with OceanBase Database by using the proxyro user. If the proxyro user does not exist or the password of the proxyro user is inconsistent with the value of the observer_sys_password parameter of ODP, ODP fails to connect to OceanBase Database, and the following error is reported:

ERROR 2013 (HY000): Lost connection to MySQL server at 'reading authorization packet', system error: 11

In this case, select a solution based on the situation.

  1. Select the following solution if the proxyro user does not exist:

    Directly connect to OceanBase Database as the root@sys user, and create the proxyro user in the sys tenant.

    create user proxyro identified by '*******';
    grant select on *.* to proxyro;
    
  2. Select one of the following solutions if the password of the proxyro user is inconsistent with the value of the observer_sys_password parameter of ODP:

    1. Directly connect to OceanBase Database as the root@sys user and change the password of the proxyro user to the value of the observer_sys_password parameter specified during ODP startup.

      ALTER USER proxyro IDENTIFIED BY 'password';
      
    2. Log in to ODP with the root@proxysys account and change the password of proxyro@sys. Then, restart ODP.

      alter proxyconfig set observer_sys_password = 'password';
      

Notice

In the preceding statement, the value of password must be the original password rather than the SHA1-hash value of the password.

Previous topic

Overview
Last

Next topic

Deploy ODP by using OCP
Next
What is on this page
Prerequisites
Choose a suitable version
Procedure
Step 1: Download and install obd
Step 2: Modify the configuration file
Step 3: Deploy ODP
Step 4: Perform a check after the installation
FAQ
Startup failed
Failed to connect to OceanBase Database