Soru

Zorluk: ZorDeploying and Managing Google Kubernetes Engine (GKE) Clusters and Workloads

An operations team needs to configure local administration and cost-optimized infrastructure for a newly created Google Kubernetes Engine (GKE) cluster named `analytics-prod-cluster` in zone `us-east1-b`. The cluster will run administrative workloads alongside fault-tolerant, stateless batch worker processes. Which TWO actions should the team perform to properly configure local cluster access and optimize node execution costs for the batch processes?

  1. Run `gcloud container clusters get-credentials analytics-prod-cluster --zone us-east1-b` to populate the local kubeconfig file with endpoint and authentication context.Cevap
  2. Provision a dedicated node pool configured with Spot VMs to host the fault-tolerant, stateless batch workloads.Cevap
  3. C
    Execute `gcloud config set container/cluster analytics-prod-cluster` on the workstation to authenticate kubectl commands against the API server.
  4. D
    Provision the primary node pool hosting stateful cluster databases using Spot VMs to lower baseline running costs.

Cevap

To configure administrative access and optimize node costs, the team must run `gcloud container clusters get-credentials analytics-prod-cluster --zone us-east1-b` to set up kubeconfig context and provision a Spot VM node pool for fault-tolerant, stateless batch workloads.
To manage a GKE cluster with kubectl, the administrator must first fetch cluster authentication credentials and update the local kubeconfig context using `gcloud container clusters get-credentials`. For cost optimization, GKE allows deploying node pools composed of Spot VMs, which provide substantial cost reductions for stateless, batch, or fault-tolerant workloads that can tolerate unexpected instance termination.

Adım Adım Çözüm

1
Configure workstation authentication for cluster management
Local kubeconfig file is populated with cluster API endpoints and credentials
kubectl requires explicit cluster context and authentication parameters, which are retrieved via the `gcloud container clusters get-credentials` command.
2
Select the optimal GKE node pool configuration for stateless batch jobs
A Spot VM node pool is deployed to run batch workloads cost-effectively
Spot VMs offer significant cost savings for stateless workloads that can recover gracefully from node preemptions.

Anahtar Kavram

GKE Cluster Credential Management and Spot VM Node Pool Workload Placement

Alternatif Yöntem

For automated CI/CD pipelines, cluster credentials can be fetched non-interactively using Service Account keys or Workload Identity before executing kubectl commands.
Tahmini Süre:2m 0s
Bu soruyu puanla