gcloud beta compute health-checks create grpc

NAME
gcloud beta compute health-checks create grpc - create a gRPC health check to monitor load balanced instances
SYNOPSIS
gcloud beta compute health-checks create grpcNAME[--check-interval=CHECK_INTERVAL; default="5s"][--description=DESCRIPTION][--enable-logging][--grpc-service-name=GRPC_SERVICE_NAME][--healthy-threshold=HEALTHY_THRESHOLD; default=2][--timeout=TIMEOUT; default="5s"][--unhealthy-threshold=UNHEALTHY_THRESHOLD; default=2][--global    |--region=REGION][--port=PORT--use-serving-port][GCLOUD_WIDE_FLAG]
DESCRIPTION
(BETA)gcloud beta compute health-checks create grpcis used to create a non-legacy health check using the gRPC protocol. You can usethis health check for Google Cloud load balancers or for managed instance groupautohealing. For more information, see the health checks overview at:https://cloud.google.com/load-balancing/docs/health-check-concepts
POSITIONAL ARGUMENTS
NAME
Name of the gRPC health check to create.
FLAGS
--check-interval=CHECK_INTERVAL; default="5s"
How often to perform a health check for an instance. For example, specifying10s will run the check every 10 seconds.The default value is5s. See $gcloud topic datetimes forinformation on duration formats.
--description=DESCRIPTION
An optional string description for the gRPC health check.
--enable-logging
Enable logging of health check probe results to Stackdriver. Logging is disabledby default.

Use --no-enable-logging to disable logging.

--grpc-service-name=GRPC_SERVICE_NAME
An optional gRPC service name string of up to 1024 characters to include in thegRPC health check request. Only ASCII characters are allowed.
--healthy-threshold=HEALTHY_THRESHOLD; default=2
The number of consecutive successful health checks before an unhealthy instanceis marked as healthy. The default is 2.
--timeout=TIMEOUT; default="5s"
If Google Compute Engine doesn't receive a healthy response from the instance bythe time specified by the value of this flag, the health check request isconsidered a failure. For example, specifying10s will cause the check to wait for 10seconds before considering the request a failure. The default value is5s. See $gcloud topic datetimes forinformation on duration formats.
--unhealthy-threshold=UNHEALTHY_THRESHOLD; default=2
The number of consecutive health check failures before a healthy instance ismarked as unhealthy. The default is 2.
At most one of these can be specified:
--global
If set, the gRPC health check is global.
--region=REGION
Region of the gRPC health check to create. If not specified, you might beprompted to select a region (interactive mode only).

To avoid prompting when this flag is omitted, you can set thecompute/region property:

gcloudconfigsetcompute/regionREGION

A list of regions can be fetched by running:

gcloudcomputeregionslist

To unset the property, run:

gcloudconfigunsetcompute/region

Alternatively, the region can be stored in the environment variableCLOUDSDK_COMPUTE_REGION.

These flags configure the port that the health check monitors.
--port=PORT
The TCP port number that this health check monitors.
--use-serving-port
If given, use the "serving port" for health checks:
  • When health checking network endpoints in a Network Endpoint Group, use the portspecified with each endpoint.--use-serving-port must be used whenusing a Network Endpoint Group as a backend as this flag specifies theportSpecification option for a Health Check object.
  • When health checking other backends, use the port of the backend service.
GCLOUD WIDE FLAGS
These flags are available to all commands:--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.

NOTES
This command is currently in beta and might change without notice. Thesevariants are also available:
gcloudcomputehealth-checkscreategrpc
gcloudalphacomputehealth-checkscreategrpc

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-05-07 UTC.