An auxiliary tenant is required to restore a table. Therefore, before you restore a table, you must create a resource pool for the auxiliary tenant in the cluster where the destination tenant resides.
Resource planning for auxiliary tenants
Since auxiliary tenants need to be created in the target cluster during table-level restore, you must reserve sufficient CPU, memory, and disk resources on the cluster before performing table-level restore. This is to prevent slow execution or failure of the restore task due to insufficient resources.
In general, it is recommended that the specifications of the auxiliary tenant match those of the source tenant. If it is not possible to match the source tenant, the minimum requirements for the auxiliary tenant are as follows:
In V4.3.5 BP2 and later, the system uses fast restore to restore auxiliary tenants during table-level restore. The following table shows the minimum specifications for a tenant in fast restore.
| Resource item | Minimum specification | Description |
|---|---|---|
| CPU | 2C or 4C | It is not recommended to set the minimum specification too small. |
| Memory | Dependent on the number of tablets | The minimum requirement is at least 1GB, with a maximum supported limit of 20,000 Tablets. |
| Storage disks | Backup data volume / 100 + Log volume to be restored | We recommend that you set the minimum capacity to at least 1% of the backup data volume plus the log volume to be restored. |
In versions earlier than V4.3.5 BP2, the system adopts full restore to recover the auxiliary tenant during table-level restore. In full restore, the minimum specifications for the auxiliary tenant are as follows.
| Resource item | Minimum specification | Description |
|---|---|---|
| CPU | 2C or 4C | It is not recommended to set the minimum specification too small. |
| Memory | Related to the number of tablets | The minimum specification requires at least 1 GB, with a maximum support of 20,000 tablets. |
| Disk | Backup data volume + restore log volume | We recommend that you set the minimum specification to be at least the sum of the backup data volume and restore log volume. |
Create a resource pool for the auxiliary tenant
Log in as the
rootuser to thesystenant of the cluster where the destination tenant resides.Create a resource unit.
Here is an example:
obclient [(none)]> CREATE RESOURCE UNIT box_16c96g MAX_CPU 16, MEMORY_SIZE = '5G', MAX_IOPS 10240, MIN_IOPS=10240;For more information about how to create a resource unit, see Create a tenant.
Create a resource pool.
We recommend that you create a resource pool that is homogeneous with the resource pool of the source tenant, namely has the same number of resource units as the resource pool of the source tenant.
Here is an example:
obclient [(none)]> CREATE RESOURCE POOL restore_pool unit = 'box_16c96g', unit_num = 1, zone_list = ('z1','z2','z3');For more information about how to create a resource pool, see Create a tenant.