Stay organized with collections Save and categorize content based on your preferences.
gcloud compute target-pools create
NAME
[--backup-pool
=BACKUP_POOL
] [--description
=DESCRIPTION
] [--failover-ratio
=FAILOVER_RATIO
] [--health-check
=HEALTH_CHECK
] [--http-health-check
=HTTP_HEALTH_CHECK
] [--region
=REGION
] [--session-affinity
=SESSION_AFFINITY
; default="NONE"] [GCLOUD_WIDE_FLAG …
]
gcloud compute target-pools create
is used to create a target pool. A target pool resource defines a group of instances that can receive incoming traffic from forwarding rules. When a forwarding rule directs traffic to a target pool, Compute Engine picks an instance from the target pool based on a hash of the source and destination IP addresses and ports. For more information on load balancing, see https://cloud.google.com/compute/docs/load-balancing-and-autoscaling/
To add instances to a target pool, use 'gcloud compute target-pools add-instances'.
NAME
--backup-pool
=BACKUP_POOL
--failover-ratio
, this flag defines the fallback behavior of the target pool (primary pool) to be created by this command. If the ratio of the healthy instances in the primary pool is at or below the specified --failover-ratio value
, then traffic arriving at the load-balanced IP address will be directed to the backup pool. If this flag is provided, then --failover-ratio
is required.
--description
=DESCRIPTION
--failover-ratio
=FAILOVER_RATIO
--backup-pool
, defines the fallback behavior of the target pool (primary pool) to be created by this command. If the ratio of the healthy instances in the primary pool is at or below this number, traffic arriving at the load-balanced IP address will be directed to the backup pool. For example, if 0.4 is chosen as the failover ratio, then traffic will fail over to the backup pool if more than 40% of the instances become unhealthy. If not set, the traffic will be directed the instances in this pool in the force
mode, where traffic will be spread to the healthy instances with the best effort, or to all instances when no instance is healthy. If this flag is provided, then --backup-pool
is required.
--health-check
=HEALTH_CHECK
--http-health-check
=HTTP_HEALTH_CHECK
--region
=REGION
To avoid prompting when this flag is omitted, you can set the
property:compute/region
gcloud config set compute/region REGION
A list of regions can be fetched by running:
gcloud compute regions list
To unset the property, run:
gcloud config unset compute/region
Alternatively, the region can be stored in the environment variable
.CLOUDSDK_COMPUTE_REGION
--session-affinity
=SESSION_AFFINITY
; default="NONE"
SESSION_AFFINITY
must be one of:
CLIENT_IP
CLIENT_IP_PROTO
NONE
--access-token-file
, --account
, --billing-project
, --configuration
, --flags-file
, --flatten
, --format
, --help
, --impersonate-service-account
, --log-http
, --project
, --quiet
, --trace-token
, --user-output-enabled
, --verbosity
.
Run $ gcloud help
for details.
gcloud alpha compute target-pools create
gcloud beta compute target-pools create
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-07 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-07 UTC."],[],[]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4