This topic describes the disks and directories required for the deployment of OceanBase Cloud Platform (OCP) Community Edition.
Database disks
MetaDB
The disk space required depends on factors such as the size of the managed cluster and stored files and the data retention period. We recommend that you reserve at least 100 GB of disk space. When the available disk space of a tenant is insufficient, you can scale out the tenant as required.
MonitorDB
If you manage no more than 10 OBServers with a moderate business traffic, we recommend that you reserve at least 150 GB of disk space. If you want to manage a large amount of business traffic, use the following method to estimate the disk space required for MonitorDB:
Estimation principles: Monitoring data can be divided into metric data and SQL execution records.
Metric data: The storage space used by each OBServer increases by 100 MB to 300 MB daily.
SQL execution records: The storage space consumption is related to the business transactions. In general, the space taken up by execution records is about 10 to 50 times of the metric data.
Based on empirical data, the size of SQL execution records on each OBServer increases by 1 GB to 40 GB per day. It is estimated to be 20 GB. OCP uses partitioned tables to store monitoring data. The retention period of the monitoring data varies with the data type:
Metric data: Second-by-second data is retained for 8 days and minute-by-minute data is retained for 31 days.
SQL execution records: retained for 8 days.
Most of the storage space is occupied by SQL execution records. You can use SQL execution records to estimate the required disk space.
Resource estimation formula: The total number of OBServers (server_count in the following example) in all managed OceanBase clusters is used for the estimation.
Estimated daily data increase for OCP MonitorDB = server_count × 20 GB
Estimated MonitorDB space requirement = Estimated daily data increase for OCP MonitorDB × 8 days
Example: Assume that you have a total of 20 OBServers running in all managed OceanBase clusters. The disk space is estimated in the following two steps:
Estimated daily data increase for OCP MonitorDB = 20 × 20 GB = 400 GB
Estimated MonitorDB space requirement = 400 GB/day × 8 days = 3200 GB, which is about 3.2 TB
Note
The preceding disk space estimation result is a ballpark figure. The actual amount of resources varies with the business transactions of MonitorDB.
The following table describes the minimum space for your reference. You need to create directories with a space greater than or equal to the minimum as required.
| Directory | Storage space | Description |
|---|---|---|
| /home/admin/observer | 20 GB | The installation directory of OceanBase Database. You must manually create the directory and make sure that the admin user has the read and write permissions on the directory. |
| /data/ | 250 GB | The directory in which the business data of OCP is stored. You must manually create the directory and make sure that the admin user has the read and write permissions on the directory. |
OCP disks
OCP is deployed in a Docker container. OCP-Server writes files to disks, and the files consume the disk space. We recommend that you reserve at least 350 GB of disk space for the OCP-Server Docker container to avoid impact on businesses due to exhausted disk space.
The following table describes the disk usage when OCP-Server is running.
| Item | Storage path | Space requirement |
|---|---|---|
| OCP program | The OCP program occupies about 1 GB of disk space after installation. The RPM packages provided with it require about 5 GB of space. Therefore, we recommend that you reserve 10 GB of space. | |
| OCP main process logs | /home/admin/logs/ocp/ | The log file size and the number of retained files are configured through OCP system parameters. By default, each log file is 100 MB large and retained for up to 100 days, and 5 to 10 files are generated each day. Therefore, we recommend that you reserve 100 GB of space. |
| OCP task logs | /home/admin/logs/task/ | No capacity limit is set. OCP periodically clears task logs to meet the target of keeping at least 20% of disk space free. Log files updated at earlier dates are cleared first. 100 GB of space needs to be reserved. |
| Local cache for OCP files | /home/admin/data/files/ | No capacity limit is set. Most of the OCP files are installation packages related to targets under OCP management, and they are mostly OceanBase installation packages. The average size of each installation package is about 500 MB. Assume that 100 installation packages are stored. 100 GB of space needs to be reserved. |