Soru

Zorluk: OrtaManaging Networking Resources

A cloud engineer is managing an existing External Application Load Balancer in Google Cloud. Monitoring reveals that healthy compute instances in the backend service are frequently marked as unhealthy during brief traffic spikes because the associated HTTP health check named prod-api-hc has an overly strict timeout setting. The engineer needs to modify prod-api-hc to increase the check interval to 15 seconds and the timeout duration to 10 seconds without recreating the resource. Which gcloud command should the engineer execute?

  1. gcloud compute health-checks update http prod-api-hc --check-interval=15s --timeout=10sCevap
  2. B
    gcloud compute backend-services update prod-api-backend --health-check-interval=15s --health-check-timeout=10s
  3. C
    gcloud compute http-health-checks update prod-api-hc --check-interval=15s --timeout=10s
  4. D
    gcloud compute health-checks create http prod-api-hc --check-interval=15s --timeout=10s

Cevap

The command 'gcloud compute health-checks update http prod-api-hc --check-interval=15s --timeout=10s' correctly updates the existing health check parameters in place.
To update an existing HTTP health check in Google Cloud without recreating it, you must use 'gcloud compute health-checks update http [NAME]' along with the desired parameter flags. This modifies the existing health check configuration in place.

Adım Adım Çözüm

1
Identify the target resource and CLI command group for Google Cloud load balancing health checks.
Modern health checks for Cloud Load Balancing are managed using the 'gcloud compute health-checks' command family.
Health checks exist as independent Google Cloud networking resources separate from backend services or instance groups.
2
Select the appropriate operation for modifying an existing health check resource.
The 'update' subcommand must be used instead of 'create' to modify parameters without deleting or re-creating the resource.
Attempting to run 'create' on an existing resource name results in a duplicate resource name error.
3
Specify the protocol type and configuration flags.
The protocol 'http' followed by flags '--check-interval=15s' and '--timeout=10s' updates the health check parameters to the desired values.
Parameters such as check interval and timeout are configured directly on the health check entity.

Anahtar Kavram

Managing Google Cloud Load Balancing Health Checks via gcloud CLI
Bu soruyu puanla