Before you create a cluster, you need to add the hosts to OCP. To create a 1-1-1 cluster, add four hosts. One host is used for each zone, and one host is used for deploying an OBProxy.
Prerequisites
The logged-in user has the ADMIN or ORG_ADMIN role.
Procedure
Log in to the OCP console.
In the left-side navigation pane, click Hosts.
On the Hosts tab, click Add Host in the upper-right corner.
Specify the IP Address and SSH Port. Enter the IPv4 or IPv6 address of the host. You can add multiple IP addresses, separated by commas. The default SSH port number is 22.
Notice
When the host IP address is an IPv6 address, the following limitations apply:
- When deploying OceanBase Database, OBClient, and OBProxy:
- The OceanBase Database version must be in the range of [V4.2.5 BP3 Hotfix3, V4.3.0) or [V4.3.5 BP2 Hotfix1, +∞).
- The OBClient version must be in the range of [V2.2.9, +∞).
- The OBProxy version must be in the range of [V4.3.4, +∞).
- The Binlog service does not support IPv6 deployment.
- When deploying OceanBase Database, OBClient, and OBProxy:
Select a host type. If no corresponding host type is available, click Create Host Specifications to add a host type in OCP.
For more information, see Manage host types.
Select an IDC. If no corresponding IDC is available, click Create IDC to add an IDC in OCP.
For more information, see Manage IDCs and Manage regions.
Select a host type, and set the connection credentials and host alias for the host.
Parameter Description Host Type The type of the host to be added. Valid values: Physical Machine and ECS. Credentials Select credentials from the password box. If no corresponding credentials are available, click Add Credential to create new connection credentials for the host.
- Credential Name: must start with a letter and end with a letter or a digit. It can contain letters, digits, and underscores. It must be 2 to 32 characters in length.
- Authorization Type: Valid values: Username/Password, SSH Private Key, and Password-Free.
- User Type: the type of the user to connect to the server. Valid values: Root User and General User.
- Root User: an SSH user with root privileges.
- General User: a regular user with root privileges. This user must be configured to execute sudo commands without a password. OCP currently supports configuring password-free execution of all commands via sudo. In other words, add
username ALL=(ALL) NOPASSWD:ALLto the/etc/sudoersfile.
- Username: required when the user type is General User. Enter the user name for connecting to the server.
- Password: required when the authorization type is Username/Password. Enter the password for connecting to the server.
- Private Key: required when the authorization type is SSH Private Key. Add an SSH credential for the server.
- OCP Private Key File Path: required when the authorization type is Password-Free. Enter the path where the host private key file is stored. The default path is
/home/admin/.ssh/id_rsa. If OCP is deployed by using Docker, use the file path in the Docker container. - Note: additional information about the credentials.
Host Alias Optional. Enter an alias for the host. (Optional) Enter a description for the host.
Click OK.
Note
If you want to customize the port number of the agent, contact OCP Technical Support for assistance.