You can specify the basic information, deployment mode, and advanced settings to create an OBProxy cluster. You can add OBProxies to the cluster or connect the cluster to an OceanBase cluster.
Prerequisites
- The current login user in the OCP console is assigned the ADMIN or ORG_ADMIN role.
- OBProxy of V4.3.0 or later supports the configuration of the RPC port.
Procedure
Log in to the OCP console.
In the left-side navigation pane, click OBProxy to go to the OBProxy page.
In the upper-right corner of the page, click Create OBProxy Cluster to go to the Create OBProxy Cluster page.
Configure the Basic Information section.
Parameter Description Cluster Name You can specify a cluster name as needed. The name must start with an English letter and can contain English letters, numbers, and underscores. Software Version Select an OBProxy version. - If the version is available in the list, select it from the list.
- If not, click Add OBLB Service to upload it.
Note
Only software packages of V1.8.0 or later are supported. For security reasons, we recommend that you select software packages of V3.1.0 or later.
Password of root@proxysys The root@proxysys account is used to log in to OBProxy and manage its parameters. You must specify the password of this account. You can specify a custom password or generate a random password. The password must meet the following complexity requirements: - It must be 8 to 32 characters in length.
- It must contain at least three of the following four types: digits (0-9), uppercase letters (A-Z), lowercase letters (a-z), and special characters. The supported special characters are
~!@#%^&*_-+=|(){}[]:;,.?/.
Password of proxyro When the Software Version of OBProxy is earlier than V4.0, this section is displayed. The proxyro account is used by OBProxy to access OceanBase clusters. If you do not specify the password, the default password of the proxyro account is used. The password must meet the following complexity requirements: - It must be 8 to 32 characters in length.
- It must contain at least three of the following four types: digits (0-9), uppercase letters (A-Z), lowercase letters (a-z), and special characters.
- The supported special characters are
~!@#%^&*_-+=|(){}[]:;,.?/.
Load Balancing Management If you enable load balancing management, you can configure OBLB to improve the load balancing capability of the OBProxy cluster. - OBLB Service: You can select an OBLB service configured on the host or click Add OBLB Service to create an OBLB service in the right-side panel. For more information, see Create Load Balancing in Manage Load Balancing.
- OBLB Service Endpoint: the endpoint of the OBLB service.
- OBLB Service Port: the port of the OBLB service. The default value is 9090.
- Username and Password: the username and password of the OBLB service. These are used for the authentication of the OBLB interface.
- VIP: the specific VIP address of OBLB.
- Access Port: the access port of OBLB. The default value is 2883.
- Port Type: the type of the access port. Supported values: RPC and SQL.
- Domain Name Configuration (Optional): the configuration information for pointing to the VIP and port. The platform does not provide a mapping between the VIP and the domain name. You must prepare a domain name resolution service.
- Note (Optional): additional information.
Note
- The Load Balancing Management feature is available only in OCP Enterprise Edition. OCP Community Edition does not support this feature.
- The Aliyun SLB feature in the Load Balancing Management section is applicable only in a dedicated cloud environment. Please contact the on-site delivery engineer.
- When OBLB and OBProxy are deployed on the same host, the OBLB access port cannot be the same as the OBProxy SQL port. Otherwise, the application cannot connect to the database.
Access Endpoint This section is displayed when Manage Load Balancer is disabled. It specifies the access endpoint of the OBProxy cluster. This parameter is used only to generate connection strings for tenants and does not affect actual usage. You must configure load balancing yourself. If the access endpoint is a VIP, you must apply for and bind it to the OBProxy server. Access Port This section is displayed when Manage Load Balancer is disabled. The default value is 2883. You must specify the access port based on the actual port of the VIP. Startup Mode The startup mode of the OBProxy cluster. Valid values: - ConfigUrl: multi-cluster startup mode. The OBProxy cluster can access multiple OceanBase clusters.
- RsList: single-cluster startup mode. The OBProxy cluster can only access the OceanBase cluster specified when the OBProxy cluster is created. After the OBProxy cluster is created, you cannot add more OceanBase clusters to it.
Connectable OceanBase Cluster The OceanBase cluster that the OBProxy cluster can access. You can select only an OceanBase cluster that has the same network as the OBProxy cluster. - When Startup Method is ConfigUrl, this parameter is not required. After the cluster is created, you can add more OceanBase clusters to the OBProxy cluster by using Add Connectable OceanBase Cluster.
- When Startup Method is RsList, this parameter is required. Select the corresponding cluster from the drop-down list.
- If the password box contains the connection credentials of the proxyro user for the cluster, the proxyro user is selected by default.
- If the password box does not contain the connection credentials of the proxyro user for the cluster, click Create Connection to create the connection credentials for the proxyro user.
(Optional) Configure Deploy OBProxy.
If you want to deploy OBProxy when you create the OBProxy cluster, configure the settings in this step. Otherwise, skip this step and deploy OBProxy after the cluster is created by using Take Over OBProxy or Add OBProxy.
Note
If you skip this step, the OBProxy cluster you create is an empty cluster. In this case, you cannot add an OceanBase cluster to the OBProxy cluster by using [Add Connectable OceanBase Cluster](300.manage-a-obproxy-cluster/200.add-a-connectable-oceanbase-cluster.md).
Turn on the switch of Deploy OBProxy.
Fill in the deployment information based on the following table.
Parameter Description IDC The IDC where OBProxy is located. One OBProxy can only be located in one IDC. Host Type Optional. If you select a host type, the host list is filtered based on the host type. Select OBProxy Host The host for deploying OBProxy. You can select multiple hosts. You can also click Add Host to add more hosts to the cluster. By default, two hosts are displayed for selection. These two hosts can deploy only two OBProxies.
If you want to deploy more OBProxies, click Add OBProxy to add more hosts.
If you want to deploy only one OBProxy, click the delete icon next to the host to delete it.
Configure the startup parameters of the OBProxy cluster.
You can add startup parameters one by one and configure their values. For more information about OBProxy parameters, see OBProxy parameters.
You can also click Parameter Template to select a parameter template. The system automatically fills in the parameters in the template and the configurations to this section. If no cluster parameter template has been created, you can click Create OBProxy Parameter Template to create a parameter template for the OBProxy cluster. For more information, see Manage OBProxy parameter templates.
The system provides two built-in templates that contain common parameters. You can directly apply the templates for the initialization settings of the OBProxy cluster.
Template Description 4.2.1 Default Parameter Template The OBProxy V4.2.1 parameter settings are recommended for production environments. Default Parameter Template for Columnar Minor Compactions The parameter settings are recommended for columnar read-only replicas in production environments. Turn on Custom Settings to configure the cluster port, operating system user, and path.
Configuration Description SQL Port The default value is 2883. You can specify a custom port. Exporter Port Number The default value is 2884. You can specify a custom port. RPC Port This port is supported only for OBProxy V4.3.0.0 and later. The default value is 2885. You can specify a custom port. Operating System User The operating system user for installing and running OBProxy. This parameter cannot be modified. You can change the default configuration by using the ocp.operation.default.os.userparameter. For more information, see Modify system parameters.Software Installation Path - When the Operating System User is admin, the Software Installation Path is
/home/admin/obproxyby default. You can specify a custom path. - When the Operating System User is not admin, the Software Installation Path is
/opt/oceanbase/obproxyby default. You can specify a custom path.
- When the Operating System User is admin, the Software Installation Path is
Click Submit to start creating the OBProxy cluster.
Note
When you install obproxy, the system checks whether the permissions on the installation directory are correct. The system supports recursive checks of the permissions on
/home/admin/logs/obproxyand its parent directory for the specified user (admin by default). If the permissions are not correct, an error is reported in the log in the following format: “check directory xxx permission failed, reason: xxx”.