This page describes how to create a read pool instance in an AlloyDB cluster.
Before you begin
- The Google Cloud project you are using must have been enabled to access AlloyDB.
- You must have one of these IAM roles in the Google Cloud project you are using:
roles/alloydb.admin(the AlloyDB Admin predefined IAM role)
roles/owner(the Owner basic IAM role)
roles/editor(the Editor basic IAM role)
If you don't have any of these roles, contact your Organization Administrator to request access.
In the Google Cloud console, go to the Clusters page.
Click a cluster in the Resource Name column.
Go to the Instances in your cluster section, and click Add read pool.
Configure your read pool instance:
In the Read pool instance ID field, enter an ID for the read pool instance.
In the Node count field, enter a node count.
The number of nodes in a read pool instance determines the instance's overall computing capacity.
Note that you can have a maximum of 20 nodes across all the read pool instances in a cluster.
Select a machine type.
Optional: Set custom flags to your instance. For each flag:
- Click Add flag.
- Select a flag from the New database flag list.
- Provide a value for the flag.
- Click Done.
Click Add read pool.
To use the gcloud CLI, you can install and initialize the Google Cloud CLI, or you can use Cloud Shell.
gcloud alloydb instances create command to create a read pool instance.
gcloud alloydb instances create INSTANCE_ID \ --instance-type=READ_POOL \ --cpu-count=CPU_COUNT \ --read-pool-node-count=NODE_COUNT \ --region=REGION_ID \ --cluster=CLUSTER_ID \ --project=PROJECT_ID
Replace the following:
- INSTANCE_ID: The ID of the instance you are creating. It must begin with a lowercase letter and can contain lowercase letters, numbers, and hyphens.
- CPU_COUNT: The number of vCPUs you want for the
instance. Valid values include:
2(2 vCPUs, 16 GB RAM)
4(4 vCPUs, 32 GB RAM)
8(8 vCPUs, 64 GB RAM)
16(16 vCPUs, 128 GB RAM)
32(32 vCPUs, 256 GB RAM)
64(64 vCPUs, 512 GB RAM)
- NODE_COUNT: The number of nodes in the instance.
Specify a number
20, inclusive. Note that you cannot have more than 20 nodes across all read pool instances in a cluster.
- REGION_ID: The region where you want the instance placed.
- CLUSTER_ID: The ID of the cluster where you want the instance placed.
- PROJECT_ID: The ID of the project where the cluster is placed.