Courseiva

CCNA Optimizing performance and cost Questions

54 questions · Optimizing performance and cost · All types, answers revealed

1
Multi-Selectmedium

A company runs a nightly batch data processing job on Compute Engine instances. The job runs for approximately 2 hours each night and is fault-tolerant (can resume from checkpoint). The team wants to minimize costs. Which TWO strategies should they implement? (Choose two.)

Select 2 answers
A.Use preemptible VMs for the worker nodes.
B.Purchase 1-year committed use discounts for the worker nodes.
C.Migrate the workload to Cloud Functions.
D.Select custom machine types tailored to the workload's resource needs.
E.Enable sustained use discounts by keeping the instances running 24/7.
AnswersA, D

Preemptible VMs cost ~60% less and are suitable for fault-tolerant batch jobs.

Why this answer

Preemptible VMs are significantly cheaper than standard VMs (up to 60-80% discount) and are ideal for fault-tolerant, short-lived batch jobs that can resume from checkpoints. Since the job runs nightly for only 2 hours and can handle interruptions, preemptible VMs minimize costs without risking job completion.

Exam trap

Google Cloud often tests the misconception that committed use discounts are always the best cost-saving strategy, but candidates must recognize that they are only cost-effective for steady-state workloads, not short-duration batch jobs.

2
Multi-Selectmedium

A DevOps engineer is reviewing GCP costs and notices high network egress charges. Which two actions can help reduce network egress costs? (Choose two.)

Select 2 answers
A.Use preemptible VMs
B.Migrate all workloads to a single zone
C.Use Cloud CDN to cache content closer to users
D.Use the same region for all GCP resources that communicate with each other
E.Use external load balancers with global access
AnswersC, D

Cloud CDN reduces egress from origin to internet by serving cached content.

Why this answer

Correct answers are C and D. Using Cloud CDN reduces egress by caching content at edge locations, minimizing data transferred from origin. Keeping resources in the same region avoids inter-region egress charges.

Option A (preemptible VMs) reduces compute costs, not network egress. Option B (single zone) does not reduce egress; resources in the same zone still incur egress if they communicate across regions. Option E (external load balancers with global access) can increase egress by routing traffic globally.

3
Drag & Dropmedium

Order the steps to respond to a Google Cloud security incident involving a compromised service account key.

Drag steps to the numbered slots on the right, or tap a step then tap a slot.

Steps
Order
1Step 1
2Step 2
3Step 3
4Step 4

Why this order

The correct order for responding to a compromised service account key is: first revoke the key to stop unauthorized use, then rotate (reissue) a new key to restore legitimate access, then audit logs to understand the scope, then assess the impact on resources, and finally update security policies to prevent future incidents. This sequence balances containment, recovery, investigation, and improvement.

4
MCQeasy

A data processing company runs nightly batch jobs that can tolerate interruptions. They want to minimize compute costs. Which compute option should they use?

A.VMs with committed use discounts
B.Preemptible VMs
C.Standard VMs with sustained use discounts
D.Sole-tenant nodes
AnswerB

Preemptible VMs offer significant cost savings (up to 80%) and are ideal for interruptible batch jobs.

Why this answer

Preemptible VMs (Option B) are the correct choice because they are significantly cheaper than standard VMs and are suitable for fault-tolerant workloads that can tolerate interruptions. Committed use discounts (A) require a 1-year or 3-year commitment but are still more expensive than preemptible VMs and not necessary for interruptible workloads. Standard VMs with sustained use discounts (C) are automatic but still more expensive.

Sole-tenant nodes (D) are dedicated hardware and are the most expensive option, typically used for compliance or licensing requirements.

5
MCQhard

A large enterprise manages costs across multiple GCP projects using a shared billing account. They want to apply a 10% discount on all committed use discounts (CUDs) to specific departments based on resource labels. How should they allocate the CUD savings?

A.Use the Cloud Billing report's 'Cost Attribution' feature to assign CUD savings based on labels
B.Enable 'CUD cost attribution' in the billing account settings to automatically distribute savings based on project labels
C.Use the Cloud Billing cost table in BigQuery with the CUD cost data and allocate using custom queries
D.Manually calculate CUD savings and distribute via journal entries
AnswerB

Google Cloud provides built-in CUD cost attribution that splits benefits across projects using labels.

Why this answer

The 'CUD cost attribution' feature in the billing account settings automatically distributes committed use discount (CUD) savings based on project labels, allowing departments to receive their share of the discount without manual effort. Option A is incorrect because 'Cost Attribution' is a feature for custom cost allocation using tags, not for CUD savings. Option C is possible using BigQuery, but it is not a built-in automated feature like CUD cost attribution.

Option D is incorrect because manual calculation and journal entries are error-prone and not recommended for automated discount allocation.

6
MCQeasy

A team wants to receive a notification when their monthly spending exceeds 80% of the budget. Which GCP feature should they configure?

A.Committed use discounts.
B.Budget alert with threshold rule at 0.8.
C.Cloud Storage bucket for cost exports.
D.Cloud Monitoring cost insights dashboard.
AnswerB

Budget alerts can be configured with threshold percentages to notify when spend reaches that level.

Why this answer

Budget alerts with threshold rules trigger notifications when spending reaches specified percentages, such as 80%.

7
MCQhard

Refer to the exhibit. A DevOps engineer configured a budget alert with Pub/Sub notifications. However, the team is not receiving alerts. The Pub/Sub subscription is set up correctly and messages can be published manually. What is the most likely reason the budget alerts are not being sent?

A.The notificationsRule does not include email recipients
B.The budget amount is specified in units without considering fractional cents
C.The threshold rules use different spend basis (CURRENT vs FORECASTED), causing inconsistency
D.The budget filter excludes credits, so actual spend might be lower than threshold
AnswerD

Credits can offset spend, so the monitored spend (excluding credits) might be below the threshold even if total spend is above.

Why this answer

The budget filter excludes credits. If credits significantly reduce actual spend, the threshold might not be met, and alerts may not fire. Option A is incorrect because the notificationsRule can be configured without email recipients if Pub/Sub is used.

Option B is incorrect because budget amounts are specified in whole units; fractional cents are not relevant. Option C is incorrect because using different spend bases (CURRENT vs FORECASTED) is allowed and does not cause inconsistency in alerting.

8
Matchingmedium

Match each SRE term to its description.

Drag a concept onto its matching description — or click a concept then click the description.

Concepts
Matches

Actual measured service performance

Target reliability level for a service

Contractual commitment to customers

Allowed downtime before SLO breach

Manual, repetitive operational work

Why these pairings

The correct matches are: SLI with a quantitative measure, SLO with a target value, SLA with a contract including consequences, and Error Budget with remaining unreliability. Common confusions include swapping Error Budget with SLI or confusing SLO with SLA.

9
MCQeasy

Refer to the exhibit. A DevOps engineer needs to view the cost report for a project. Which role should be granted at the organization level to allow viewing billing data for all projects in the organization?

A.roles/billing.admin
B.roles/billing.creator
C.roles/billing.viewer
D.roles/billing.user
AnswerC

Billing viewer has read access to billing data for the entire billing account.

Why this answer

Roles/billing.viewer provides read-only access to billing data for all projects in the organization when granted at the organization level. Option A (roles/billing.admin) is too permissive as it allows modifying billing settings. Option B (roles/billing.creator) is used to create billing accounts and does not grant view access to cost reports.

Option D (roles/billing.user) is not a valid predefined role for viewing billing data; it only allows linking projects to billing accounts.

10
MCQhard

A DevOps engineer notices that the budget alerts for a project are not triggering even though spending exceeds thresholds. The budget is configured at the billing account level, filtering for that project only. The project is linked to the correct billing account. What is the most likely cause?

A.The budget filter excludes credit types, and the spending includes credits that reduce the effective spend below threshold
B.The budget amount is set in units of 1000, so $5000 is actually 5 units, causing confusion
C.The budget notifications are only sent to Pub/Sub, and no subscriber is active
D.The budget filter includes services that are not used in the project
AnswerC

Without an active subscriber, Pub/Sub messages are not delivered.

Why this answer

Budget notifications are configured to be sent to a Pub/Sub topic when spending exceeds thresholds. If there is no active subscription on that topic, the messages are not consumed, and therefore no alerts are triggered or delivered. Option A is unlikely because the budget filter excluding credit types does not prevent alerting; it simply means credits are not considered in the spend calculation.

Option B is incorrect because Google Cloud budgets are set in actual currency units, not in units of 1000. Option D is incorrect because including services that are not used does not affect the alert threshold; it simply means those services have zero spend.

11
MCQhard

A company runs a large-scale data processing workload on Dataflow. The pipeline processes streaming data from Pub/Sub and writes results to BigQuery. The current monthly Dataflow cost is $50,000, and the company wants to reduce it. They have already optimized the pipeline code and reduced data shuffling. They notice that the Dataflow workers are running at 100% CPU for most of the time, but the job's autoscaling is set to 'throughput-based' and currently uses 20 workers. The job's latency SLAs are tight. They consider switching to 'flexible resource scheduling' (FlexRS) to reduce costs. What should they evaluate before enabling FlexRS?

A.FlexRS reduces costs by using slower disk types, which may impact performance.
B.FlexRS requires using preemptible VMs, which may cause data loss.
C.FlexRS may increase pipeline latency because it is designed for batch jobs with looser latency requirements.
D.FlexRS is only available for batch pipelines, not streaming.
AnswerD

Flexible Resource Scheduling (FlexRS) is a feature for batch Dataflow pipelines to reduce costs; it cannot be enabled for streaming pipelines.

Why this answer

FlexRS (Flexible Resource Scheduling) is a feature designed for batch Dataflow pipelines that can tolerate longer startup times and preemptible VMs, but it is not available for streaming pipelines. The question states the pipeline is streaming (Dataflow processing streaming data from Pub/Sub), so FlexRS cannot be applied. Option A is incorrect because FlexRS does not use slower disk types; it uses preemptible VMs and slower startup but not disks.

Option B is incorrect because while FlexRS does use preemptible VMs, it does not cause data loss; Dataflow handles preemption gracefully, and the pipeline is streaming anyway which is not eligible. Option C is incorrect because FlexRS is not about latency; it's about cost savings via preemption and slower startup, and again it's not for streaming.

12
MCQmedium

A company is using Google Kubernetes Engine (GKE) with multiple node pools. They notice that their monthly costs are higher than expected. Upon review, they find that several preemptible VMs are being recreated frequently, leading to sustained usage costs. What is the most cost-effective solution to reduce costs?

A.Purchase committed use discounts for the preemptible VMs.
B.Increase the number of preemptible VMs to spread the workload.
C.Enable sustained use discounts for the existing VMs.
D.Migrate to Spot VMs, which have a lower price and no maximum runtime.
AnswerD

Spot VMs are the recommended replacement for preemptible VMs and offer lower costs without the 24-hour limit.

Why this answer

Spot VMs are the recommended replacement for preemptible VMs, offering the same low price but without the 24-hour maximum runtime limit. This eliminates the frequent recreation and sustained usage costs caused by preemptible VMs being terminated and restarted, directly reducing monthly expenses.

Exam trap

Google Cloud often tests the misconception that preemptible VMs are the cheapest option, but the trap here is that Spot VMs are actually cheaper and have no maximum runtime, making them superior for cost reduction.

How to eliminate wrong answers

Option A is wrong because committed use discounts (CUDs) cannot be applied to preemptible or Spot VMs; CUDs are only available for regular (on-demand) VMs and require a 1- or 3-year commitment, which would increase costs for short-lived workloads. Option B is wrong because increasing the number of preemptible VMs would amplify the frequency of recreations and associated sustained usage costs, not reduce them. Option C is wrong because sustained use discounts are automatically applied to on-demand VMs based on monthly usage, but preemptible VMs are not eligible for sustained use discounts; enabling them has no effect on preemptible VM costs.

13
MCQhard

An e-commerce company uses Cloud SQL for MySQL to support their online store. The database has a 500GB dataset. They notice that monthly costs have increased significantly. On reviewing the billing export to BigQuery, they see that the highest cost is from 'Cloud SQL - Storage' and 'Cloud SQL - Backups'. They currently have automated backups enabled with a retention of 7 days. They also take manual backups before every deployment, which are stored for 30 days. They want to reduce backup storage costs without compromising disaster recovery. What should they do?

A.Reduce automated backup retention to 2 days and keep manual backups as is.
B.Reduce manual backup retention to 7 days and increase automated backup retention to 14 days.
C.Use Cloud SQL's point-in-time recovery (PITR) feature instead of manual backups.
D.Export backups to Cloud Storage and delete old ones from Cloud SQL.
AnswerD

Exporting backups to Cloud Storage allows you to use cheaper storage classes (e.g., Nearline) and delete the original backups from Cloud SQL, reducing costs.

Why this answer

Exporting backups to Cloud Storage and then deleting from Cloud SQL reduces storage costs since Cloud Storage has cheaper classes. Option A reduces retention but may risk data loss. Option B still retains many backups.

Option C (PITR) requires binary logs, which also incur storage costs.

14
MCQmedium

Refer to the exhibit. A DevOps engineer noticed that the nightly batch processing costs are higher than expected. After running the above command, what is the most likely cause?

A.The instances are not preemptible, leading to higher compute costs
B.The instances are running in different zones, increasing egress costs
C.The instances are using the n2-standard-4 machine type, which is expensive
D.The instances have automatic restart enabled, incurring additional charges
AnswerA

Correct. Preemptible VMs are cheaper and suitable for fault-tolerant batch jobs. The instances are not preemptible, so costs are higher.

Why this answer

The instances are not preemptible, leading to higher compute costs. For batch jobs that tolerate interruptions, preemptible VMs are more cost-effective. Option B is incorrect because instances in different zones within the same region do not significantly increase egress costs for batch processing.

Option C is incorrect because the n2-standard-4 machine type is standard and cost-effective for batch jobs; the issue is the pricing model (on-demand vs preemptible). Option D is incorrect because automatic restart does not incur additional charges.

15
Multi-Selectmedium

A DevOps team is analyzing Google Cloud costs and notices that spending on BigQuery has increased significantly. They want to reduce costs without impacting ongoing analytical workloads. Which TWO actions should they take? (Choose two.)

Select 2 answers
A.Switch to on-demand pricing to pay only for queries run.
B.Enable column-level security to restrict access to sensitive data.
C.Set custom cost controls like query quotas and maximum bytes billed per query.
D.Delete unused datasets to reduce storage costs.
E.Implement flat-rate pricing with reservations for consistent workloads.
AnswersC, E

Limits prevent expensive queries from running unbounded.

Why this answer

BigQuery allows you to set custom cost controls such as query quotas (e.g., concurrent queries per project) and maximum bytes billed per query. These controls cap resource usage at the query level, preventing runaway costs while still allowing analytical workloads to run within defined limits. This directly addresses cost spikes without blocking ongoing operations.

Exam trap

The trap here is that candidates confuse storage cost reduction (Option D) with the primary driver of BigQuery cost spikes on Google Cloud, which is almost always query compute (bytes processed), not storage, and they may overlook that Google Cloud BigQuery flat-rate pricing (Option E) is a valid cost-reduction strategy for consistent workloads.

16
Multi-Selecthard

An organization wants to optimize BigQuery costs. Which three practices should they implement? (Choose three.)

Select 3 answers
A.Store data in multiple tables per day without partitioning
B.Set a maximum bytes billed per query at the project level
C.Use table partitioning and clustering to reduce data scanned
D.Purchase BigQuery flat-rate reservations for all queries
E.Use authorized views to restrict data access instead of copying data
AnswersB, C, E

Prevents runaway queries from incurring high costs.

Why this answer

Options B, C, and E are correct. Setting a maximum bytes billed per query at the project level prevents cost overruns. Table partitioning and clustering reduce the amount of data scanned per query, lowering costs.

Authorized views allow controlled access without duplicating data, avoiding storage costs. Option A is incorrect because storing data in multiple tables without partitioning increases data scanned and costs. Option D is incorrect because purchasing flat-rate reservations for all queries may not be cost-effective for variable workloads; on-demand pricing can be cheaper.

17
MCQmedium

A DevOps engineer is responsible for cost optimization of GKE clusters. They have identified that many nodes are underutilized. What is the best approach to reduce costs without impacting availability?

A.Enable cluster autoscaler to automatically scale down nodes
B.Use spot VMs for all node pools
C.Delete underutilized nodes manually
D.Migrate to a single zone cluster
AnswerA

Cluster autoscaler adjusts node count based on demand, saving costs.

Why this answer

Cluster autoscaler automatically scales down nodes when they are underutilized. Option B is manual and not scalable. Option C may cause disruptions.

Option D reduces availability.

18
MCQeasy

Refer to the exhibit. What does this recommendation suggest?

A.Change the instance to preemptible.
B.Upgrade the instance.
C.Delete the instance.
D.Downgrade the instance.
AnswerB

The description says 'Upgrade instance'.

Why this answer

The description explicitly states to upgrade the instance from n1-standard-2 to n1-standard-4, indicating a need for more resources.

19
MCQeasy

A DevOps engineer notices that the monthly compute cost is higher than expected for a Kubernetes Engine cluster. They want to identify which namespaces or workloads are contributing most to the cost. What should they do?

A.Enable Logging for all containers and analyze logs.
B.Use Cloud Monitoring dashboards with Kubernetes metrics.
C.Add labels to nodes and use Cost Table reports.
D.Enable GKE Usage Metering and export to BigQuery.
AnswerD

GKE Usage Metering provides cost attribution by namespace and workload.

Why this answer

GKE Usage Metering exports detailed per-cluster resource consumption data (CPU, memory, storage, and network) to BigQuery, enabling cost attribution by namespace, label, or workload. This is the only option that directly provides granular cost breakdowns for Kubernetes resources, allowing the engineer to identify which namespaces or workloads drive compute costs.

Exam trap

The trap here is that candidates confuse monitoring metrics (CPU/memory usage) with cost data, or assume node labels and billing reports alone provide namespace-level granularity, missing that GKE Usage Metering is the specific tool designed for this exact use case.

How to eliminate wrong answers

Option A is wrong because enabling Logging for all containers and analyzing logs would capture application events and errors, not resource usage or cost data; logs lack the structured cost metrics needed for cost attribution. Option B is wrong because Cloud Monitoring dashboards with Kubernetes metrics show real-time performance data (e.g., CPU utilization, memory usage) but do not provide cost data or billing-level attribution per namespace or workload. Option C is wrong because adding labels to nodes and using Cost Table reports (a reference to Google Cloud's Cost Table in the billing console) can help categorize costs by label, but without GKE Usage Metering, node labels alone do not capture per-workload or per-namespace resource consumption; the Cost Table reports aggregate billing data at the project or service level, not at the granularity of Kubernetes namespaces.

20
MCQmedium

A company has multiple projects under an organization. They want to allocate costs to different departments based on project labels. They have applied labels to all resources, but the cost reports show 'Unlabeled' for many resources. What is the most likely cause?

A.Labels are not propagated to billing export.
B.The billing export is not configured.
C.The project uses a different billing account.
D.Labels were applied after the billing period.
AnswerD

Historical cost data does not retroactively update with new labels.

Why this answer

Labels applied after the billing period do not apply to historical data; they only appear in future billing reports.

21
MCQeasy

A DevOps team wants to get a monthly report of GCP costs broken down by service and project. What is the simplest way to achieve this?

A.Export billing data to BigQuery and run a scheduled query
B.Use the gcloud CLI to run a billing query each month
C.Use the Cloud Billing reports page to export a CSV directly
D.Set up a Cloud Function to call the Cloud Billing API and generate a report
AnswerC

Billing reports provide a user interface with filtering and export capabilities.

Why this answer

The simplest way to get a monthly report of GCP costs broken down by service and project is to use the Cloud Billing reports page. This page provides pre-built reports that can be filtered by service and project, and allows direct CSV export without any additional setup or complexity. Option A (BigQuery export) is more complex and requires scheduling queries.

Option B (gcloud CLI) requires manual execution each month. Option D (Cloud Function) is overkill for a simple monthly report.

22
Multi-Selectmedium

A company is using Google Cloud and wants to monitor and control costs. Which TWO actions should they take? (Choose two.)

Select 2 answers
A.Set up budget alerts to notify when spending exceeds thresholds.
B.Use labels to categorize resources and track costs by team.
C.Disable all unnecessary APIs at the organization level.
D.Export billing data to BigQuery for detailed analysis.
E.Grant billing account access to all project owners.
AnswersA, B

Budget alerts help monitor and control costs by providing notifications.

Why this answer

Setting up budget alerts (option A) is a core cost control action because it allows you to define a budget amount and receive notifications when actual or forecasted spending exceeds a specified threshold (e.g., 50%, 90%, 100%). This enables proactive intervention before costs spiral out of control. Using labels (option B) to categorize resources (e.g., by team, project, or environment) allows you to track and allocate costs accurately in billing reports, making it easier to identify cost drivers and enforce accountability.

Exam trap

Google Cloud often tests the distinction between cost monitoring (e.g., exporting to BigQuery) and cost control (e.g., budget alerts and labels), so candidates mistakenly select options that only provide visibility rather than active enforcement or categorization.

23
MCQhard

A company runs a production workload on Google Kubernetes Engine (GKE) with cluster autoscaling enabled. The cluster has three node pools: one for general-purpose workloads (n1-standard-4), one for memory-intensive workloads (n2-highmem-8), and one for GPU-accelerated jobs (with 1 NVIDIA Tesla T4 per node). The workloads are a mix of stateless microservices and stateful databases. Over the past month, the monthly GKE cost has increased by 40% despite no significant change in application traffic or resource requests. The team has verified that vertical pod autoscaling and node auto-provisioning are enabled. They have also checked that there are no orphaned resources. They suspect that overspending is due to inefficient resource utilization or node selection. What should the team do to identify and reduce the unnecessary cost?

A.Review billing export data in BigQuery to identify the top cost contributors by project, service, and label.
B.Use the GKE cost optimization recommender to identify idle resources and apply recommended changes.
C.Disable node auto-provisioning and switch all nodes to preemptible instances.
D.Create a budget alert for the GKE service and set a hard limit to prevent further overspend.
AnswerB

The recommender provides specific, actionable insights to reduce costs without impacting workload stability.

Why this answer

The GKE cost optimization recommender specifically analyzes cluster utilization patterns, such as underutilized nodes or pods, and provides actionable recommendations to right-size resources. Since the team has already verified that VPA and node auto-provisioning are enabled and no orphaned resources exist, the recommender can pinpoint inefficiencies like over-provisioned node pools or idle GPU nodes that are driving the 40% cost increase despite stable traffic.

Exam trap

The trap here is that candidates confuse high-level billing analysis (Option A) with actionable optimization recommendations, or they assume that disabling auto-provisioning and using preemptible instances (Option C) is a universal cost-saving fix without considering workload compatibility and the need for diagnostic insights first.

How to eliminate wrong answers

Option A is wrong because reviewing billing export data in BigQuery identifies cost contributors at a high level (project, service, label) but does not provide granular, actionable recommendations for GKE resource optimization; it lacks the specific node-level and pod-level analysis needed to address inefficient utilization. Option C is wrong because disabling node auto-provisioning and switching all nodes to preemptible instances is a drastic change that could cause workload disruption for stateful databases (which require persistent nodes) and does not address the root cause of inefficient resource utilization; preemptible instances are not suitable for stateful workloads due to their 24-hour maximum lifetime and potential for sudden termination. Option D is wrong because creating a budget alert with a hard limit only prevents further overspend by stopping or alerting on cost, but does not identify or reduce the existing inefficiencies; it is a reactive measure, not a diagnostic or optimization tool.

24
Multi-Selecteasy

A company wants to set budgets and alerts for a GCP project. Which two steps are required to enable budget notifications via email? (Choose two.)

Select 2 answers
A.Enable the Cloud Billing API for the project
B.Create a budget alert threshold in the Cloud Console
C.Add the email recipients in the budget configuration
D.Create a Pub/Sub topic and subscribe to it
E.Set up a Cloud Function to send emails
AnswersB, C

Thresholds are required to trigger alerts based on spending.

Why this answer

Options B and C are required. You must create a budget alert threshold in the Cloud Console to define the spending limit, and then add email recipients in the budget configuration to receive notifications. Option A (Enabling the Cloud Billing API) is not a prerequisite for email notifications; it is needed for programmatic access.

Options D and E are for programmatic notifications, not email.

25
Multi-Selecthard

A company uses BigQuery on-demand pricing. They want to reduce costs without changing usage patterns. Which THREE strategies are effective? (Choose three.)

Select 3 answers
A.Use clustered tables.
B.Use materialized views.
C.Use legacy SQL instead of standard SQL.
D.Use flat-rate pricing.
E.Use partitioned tables.
AnswersA, B, E

Clustering columates data, allowing queries to scan fewer blocks.

Why this answer

Partitioning and clustering reduce data scanned per query. Materialized views precompute results to reduce scanned data on repeated queries.

26
MCQmedium

A company has multiple projects in an organization. They want to set a budget of $5000 per month on a specific project and receive notifications when spending reaches 50% and 90%. What should they do?

A.Use the Cloud Billing API to monitor spending and send custom alerts
B.Create a budget at the organization level with alert thresholds of 50% and 90%
C.Configure a Pub/Sub topic and set up a cloud function to check spending daily
D.Create a budget at the project level with alert thresholds of 50% and 90%
AnswerD

Creating a budget at the project level with alert thresholds of 50% and 90% directly meets the requirement and is the simplest, most straightforward approach.

Why this answer

Budgets can be created at the project level with alert thresholds, allowing you to set a $5000 budget on a specific project and receive notifications at 50% and 90%. Option A is incorrect because while the Cloud Billing API can be used to monitor spending and send custom alerts, it is more complex and not the recommended or simplest approach for this requirement. Option B is incorrect because a budget at the organization level would apply to all projects, not just the specific project.

Option C is incorrect because although a Pub/Sub topic and cloud function could be configured to check spending daily, it is overengineering; the built-in budget alerts are simpler and more appropriate.

27
Drag & Dropmedium

Arrange the steps to troubleshoot a high latency issue on a Google Cloud HTTP(S) Load Balancer.

Drag steps to the numbered slots on the right, or tap a step then tap a slot.

Steps
Order
1Step 1
2Step 2
3Step 3
4Step 4

Why this order

Start with health checks, then logs, metrics, identify culprit, and take action.

28
MCQeasy

Refer to the exhibit. The output shows a recommendation from the Cloud Cost Optimization recommender for an instance in us-central1-a. The instance is a production web server that consistently runs at 25% CPU utilization during peak hours. What should the DevOps engineer do to implement this recommendation with minimal risk?

A.Stop the instance, change the machine type to n2-standard-4, and start it again.
B.Ignore the recommendation because the instance is production and any change might cause downtime.
C.Add a second n2-standard-4 instance behind a load balancer to distribute load.
D.Use a custom machine type with 4 vCPUs and 32 GB memory to ensure enough RAM.
AnswerA

This directly implements the recommendation with minimal risk.

Why this answer

The Cloud Cost Optimization recommender has identified that the current instance is over-provisioned for its actual workload (25% CPU utilization during peak hours). By stopping the instance, changing the machine type to n2-standard-4 (which has 4 vCPUs and 16 GB RAM, matching the recommended 4 vCPUs and 15 GB memory), and starting it again, the engineer rightsizes the instance without incurring downtime during the change itself. This approach minimizes risk because the instance is stopped only briefly for the machine type change, and the new machine type is a standard, well-tested configuration that aligns with the recommender's analysis.

Exam trap

Google Cloud often tests the misconception that production instances should never be modified, but the correct approach is to use the recommender's suggestion with a controlled stop/start process, which minimizes risk and is a standard cost optimization practice.

How to eliminate wrong answers

Option B is wrong because ignoring the recommendation is not a valid cost optimization strategy; the recommender is designed to identify safe rightsizing opportunities, and the instance can be changed with minimal downtime by stopping and restarting it. Option C is wrong because adding a second n2-standard-4 instance behind a load balancer would increase costs and complexity, not reduce them, and the single instance is already underutilized at 25% CPU. Option D is wrong because using a custom machine type with 4 vCPUs and 32 GB memory would double the recommended memory (15 GB), leading to unnecessary cost and not addressing the over-provisioning issue identified by the recommender.

29
MCQmedium

A company uses Compute Engine with committed use discounts for 1-year. They need to reduce costs further. What should they do?

A.Use sustained use discounts instead.
B.Use preemptible VMs for all workloads.
C.Rightsize their VMs based on recommender recommendations.
D.Increase committed use discount term to 3 years.
AnswerC

Rightsizing reduces resource usage, directly lowering costs.

Why this answer

Rightsizing based on recommender recommendations reduces resource usage without changing pricing model, offering immediate cost savings.

30
Multi-Selectmedium

Which THREE actions can help optimize Cloud Storage costs? (Choose three.)

Select 3 answers
A.Use Nearline or Coldline storage classes for infrequently accessed data.
B.Enable Object Lifecycle management to transition objects to colder storage classes.
C.Compress objects before uploading to reduce storage size.
D.Enable versioning on all buckets to protect against accidental deletion.
E.Use Standard storage class for all objects to ensure low latency.
AnswersA, B, C

These classes offer lower storage costs for infrequent access.

Why this answer

Nearline and Coldline storage classes are designed for infrequently accessed data, offering lower storage costs compared to Standard storage. By choosing these classes for data that is accessed less than once a quarter or once a year, you reduce the per-GB storage charge, though you incur higher retrieval and early deletion fees. This directly optimizes costs when access patterns align with the class's intended use.

Exam trap

The trap here is that candidates may confuse data protection features (like versioning) or performance choices (like Standard class) with cost optimization actions, overlooking that versioning increases storage costs and Standard is the most expensive class.

31
MCQhard

Refer to the exhibit. The company received an alert when the threshold was triggered. What does this alert indicate?

A.The actual spend has reached 50% of the budget.
B.The spend has exceeded the budget amount.
C.The forecasted spend is projected to exceed 50% of the budget.
D.Both actual and forecasted spend thresholds have been crossed.
AnswerA

CURRENT_SPEND triggers on actual spend.

Why this answer

The threshold rule uses a CURRENT_SPEND basis, so the alert triggers when actual costs reach 50% of the budget. This corresponds to Option A. Option B describes exceeding the budget, Option C describes a forecasted exceedance, and Option D describes both thresholds, none of which are indicated by this alert.

32
MCQeasy

A company uses BigQuery on-demand pricing. To control costs, they want to prevent any single query from scanning more than 1 TB of data. How can they enforce this?

A.Set a custom cost budget with alert at 1 TB
B.Use the maximum bytes billed parameter in the query settings
C.Use BigQuery reservations with 1 TB slot capacity
D.Set a query quota in the GCP Console quota page
AnswerB

This parameter limits the amount of data a query can scan.

Why this answer

BigQuery allows setting a maximum bytes billed parameter per query, which limits the amount of data scanned. Option A is a budget alert, not a per-query limit. Option C uses reservations, which allocate slots but don't limit per-query data scanned.

Option D refers to quotas, which are not per-query data limits.

33
MCQeasy

A startup wants to reduce their Google Cloud costs for a batch processing job that runs nightly for 3 hours. The job is fault-tolerant and can tolerate interruptions. What is the most cost-effective compute option?

A.Standard VM
B.Shielded VM
C.Sole-tenant node
D.Preemptible VM
AnswerD

Preemptible VMs cost up to 60-91% less than standard VMs and are ideal for fault-tolerant workloads.

Why this answer

Preemptible VMs (Option D) are the most cost-effective because they offer up to 60-91% discount and are suitable for fault-tolerant, interruptible batch jobs. Standard VMs (Option A) are more expensive. Shielded VMs (Option B) provide security features but no cost savings.

Sole-tenant nodes (Option C) provide isolation but are more costly.

34
Multi-Selecteasy

A company is moving large amounts of data between regions. Which two actions can reduce network egress costs? (Choose two.)

Select 2 answers
A.Consolidate resources to a single region
B.Use Cloud CDN to cache static content
C.Use Cloud Interconnect to connect to on-premises
D.Use a VPN connection to on-premises
E.Use VPC Network Peering within the same VPC network
AnswersA, B

Moving all resources to one region eliminates cross-region egress costs entirely.

Why this answer

Options A and B are correct. Consolidating resources to a single region eliminates cross-region egress, directly reducing costs. Using Cloud CDN to cache static content serves requests from edge locations, reducing egress from the origin.

Options C, D, and E are incorrect: Cloud Interconnect primarily reduces egress costs to on-premises, not between regions; VPN uses the public internet and still incurs egress charges; VPC Network Peering within the same region is free but does not reduce cross-region egress, and peering across regions still incurs costs.

Exam trap

A common mistake is thinking Cloud Interconnect reduces inter-region egress, but it is for on-premises connectivity. Also, VPC peering is free within the same region but does not reduce cross-region costs.

35
MCQmedium

Refer to the exhibit. A DevOps engineer wants to reduce compute costs immediately. Which action is most effective?

A.Delete the terminated instance.
B.Rightsize instance-2 from n1-standard-8 to n1-standard-4.
C.Change instance-1 to a non-preemptible instance.
D.Move instance-1 to a different zone.
AnswerB

Reducing the machine size saves cost.

Why this answer

Rightsizing instance-2 from n1-standard-8 to n1-standard-4 reduces vCPUs from 8 to 4, directly lowering cost. The terminated instance incurs no cost, and the preemptible instance is already cost-effective. Zone changes do not affect cost.

36
MCQeasy

A company wants to receive notifications when their Google Cloud costs exceed $5000 in a month. They have set a budget alert at the billing account level. What is the minimum configuration required to ensure they get alerted?

A.Set budget amount to $5000 and alert threshold at 100% and configure a Pub/Sub topic for notifications.
B.Set budget amount to $5000 and alert threshold at 100%.
C.Set budget amount to $5000 and alert threshold at 50% and 100%.
D.Set budget amount to $5000 and alert threshold at 100% and ensure the budget is scoped to a single project.
AnswerA

This includes both the threshold and a notification channel (Pub/Sub or email), meeting the minimum requirement.

Why this answer

It sets the budget amount to $5000, an alert threshold at 100%, and importantly configures a Pub/Sub topic for notifications. Without a notification channel (Pub/Sub or email), alerts are not delivered. Option B lacks a notification channel.

Option C includes unnecessary thresholds and still has no notification. Option D incorrectly scopes to a single project, which is not required and could miss costs from other projects under the billing account.

37
MCQhard

You are a DevOps engineer at a large e-commerce company that runs its production workloads on Google Kubernetes Engine (GKE) in the us-central1 region. The cluster has 500 nodes, each with 8 vCPUs and 32 GB of memory, and uses preemptible VMs for cost savings. Over the past month, the monthly GKE cost has increased by 30% unexpectedly. Upon reviewing the billing reports, you notice a significant spike in Compute Engine costs, specifically for 'Sustained Use Discount' line items, but the total cost is higher than expected. You also observe that the cluster's node utilization is inconsistent, with some nodes running at 90% CPU and memory while others are below 20%. Your team has been deploying stateless microservices and using Cluster Autoscaler with default settings. The application traffic is variable but predictable, with peaks on weekends. You need to reduce the GKE costs without impacting performance. What should you do?

A.Enable node auto-provisioning and migrate baseline workloads to nodes covered by committed use discounts (1-year or 3-year).
B.Increase the minimum number of nodes in the cluster to 300 and use a larger machine type to reduce the number of pods per node.
C.Switch the cluster to a single-zone configuration and reduce the number of nodes to 200 to lower base costs.
D.Reduce the number of preemptible VMs to 30% and use only on-demand VMs for the remaining nodes to improve reliability.
AnswerA

Node auto-provisioning optimizes resource allocation based on pod requirements, and CUDs provide significant savings for stable workloads.

Why this answer

Enabling node auto-provisioning allows GKE to automatically select the most cost-effective node configurations for your workloads, reducing waste from over-provisioned nodes. Migrating baseline workloads to nodes covered by committed use discounts (CUDs) locks in lower prices for predictable usage, directly addressing the 30% cost spike caused by inconsistent utilization and unexpected sustained use discount charges. This combination optimizes both variable and steady-state workloads without sacrificing performance.

Exam trap

Google Cloud often tests the misconception that simply reducing node count or switching to cheaper VM types (like preemptible) will solve cost issues, without addressing the root cause of inconsistent utilization and the need for committed use discounts for baseline workloads.

How to eliminate wrong answers

Option B is wrong because increasing the minimum number of nodes to 300 and using larger machine types would increase, not reduce, costs by forcing more idle capacity and higher base compute charges. Option C is wrong because switching to a single-zone configuration reduces resilience and availability, and simply reducing node count to 200 does not address the root cause of inconsistent utilization or the sustained use discount anomaly. Option D is wrong because reducing preemptible VMs to 30% and using more on-demand VMs would raise costs significantly, as preemptible VMs are cheaper; the issue is utilization, not reliability.

38
Multi-Selecthard

A company runs a web application on Google Kubernetes Engine (GKE) with multiple services. They want to reduce costs without impacting performance. Which THREE actions should they take? (Choose three.)

Select 3 answers
A.Enable cluster autoscaling and manually scale nodes based on peak load.
B.Deploy a service mesh like Istio to optimize traffic routing.
C.Enable node auto-provisioning to automatically adjust node pools.
D.Right-size CPU and memory requests and limits for each service.
E.Use preemptible VMs for stateless, fault-tolerant workloads.
AnswersC, D, E

Node auto-provisioning ensures the cluster uses the right size and type of nodes.

Why this answer

Node auto-provisioning in GKE automatically creates and scales node pools based on the resource requirements of pending pods. This eliminates the need for manual node pool management and ensures that only the necessary compute resources are provisioned, reducing costs without manual intervention or over-provisioning.

Exam trap

Google Cloud often tests the misconception that manual scaling or service meshes are cost-saving measures, when in fact they either increase costs or fail to address the root cause of over-provisioning.

39
Multi-Selectmedium

A company wants to optimize costs for their Google Kubernetes Engine (GKE) clusters. Which three best practices should they implement? (Choose three.)

Select 3 answers
A.Use node auto-provisioning to dynamically add nodes
B.Use regional clusters instead of zonal clusters
C.Use committed use discounts for long-running workloads
D.Use pod resource requests and limits appropriately
E.Use preemptible nodes for stateless workloads
AnswersC, D, E

Committed use discounts provide significant savings for predictable, steady-state workloads.

Why this answer

The correct answers are C, D, and E. Committed use discounts (C) reduce costs for predictable, long-running workloads by offering a discount in exchange for a commitment to use a certain amount of resources. Properly setting pod resource requests and limits (D) prevents overprovisioning and ensures efficient resource utilization, directly reducing costs.

Preemptible nodes (E) are short-lived, cheaper instances ideal for stateless, fault-tolerant workloads, offering significant cost savings. Option A (node auto-provisioning) can help right-size clusters but is not a direct cost optimization practice—it may even increase costs if not carefully configured. Option B (regional clusters) improves availability but incurs higher costs due to multi-zone replication, so it is not a cost-saving measure.

40
MCQhard

A company uses BigQuery for analytics with many queries scanning terabytes daily. They need to reduce query costs without reducing usage. What is the most effective strategy?

A.Reserve capacity in specific regions.
B.Use flat-rate pricing with slots.
C.Partition and cluster tables.
D.Use standard SQL instead of legacy SQL.
AnswerC

Partitioning and clustering limit the data scanned per query, reducing cost.

Why this answer

Partitioning and clustering tables reduce the amount of data scanned per query, directly lowering costs.

41
MCQhard

A company has purchased Compute Engine committed use discounts (CUD) for 1 year for vCPU and memory. After 3 months, they need to upgrade some VMs to a larger machine type. What happens to the CUD coverage?

A.The CUD is automatically adjusted to cover the new machine type
B.The CUD continues to apply to the original resource, and any additional usage is charged at on-demand rates
C.The CUD applies only to the specific machine types in the commitment, so upgrades are not covered
D.The CUD is voided and a refund is issued
AnswerB

CUD covers the committed vCPU and memory; if you upgrade, the CUD still applies to the original amount, and extra usage is on-demand.

Why this answer

Committed Use Discounts (CUDs) apply to resource usage (vCPU, memory) rather than specific machine types. When upgrading to a larger machine type, the original committed resources are still used; any additional usage beyond the committed amount is charged at on-demand rates. Option A is incorrect because CUDs are not automatically adjusted.

Option C is incorrect because CUDs do cover upgrades as long as the resource types match. Option D is incorrect because CUDs are not voided or refunded.

42
MCQeasy

A company uses Cloud Storage to store archival data. They want to minimize storage costs while maintaining availability. Which storage class should they use?

A.Nearline storage class.
B.Standard storage class.
C.Archive storage class.
D.Coldline storage class.
AnswerC

Archive is the lowest-cost storage class for long-term archival data.

Why this answer

The Archive storage class is the correct choice because it offers the lowest storage cost for archival data that is accessed less than once per year, with a 365-day minimum storage duration and retrieval costs that are higher than other classes. This aligns with the requirement to minimize storage costs while maintaining availability, as Archive data is still available for retrieval (though with a longer latency) and is replicated for durability.

Exam trap

The trap here is that candidates often confuse 'Coldline' with the cheapest option because of its name, but Archive is actually the lowest-cost class for truly archival data, and Google Cloud tests whether you know the specific access frequency and minimum storage duration differences between Coldline and Archive.

How to eliminate wrong answers

Option A is wrong because Nearline is designed for data accessed less than once per 30 days, not for archival data, and has higher storage costs than Archive. Option B is wrong because Standard is for frequently accessed data (e.g., multiple times per month) and has the highest storage cost, making it unsuitable for minimizing costs on archival data. Option D is wrong because Coldline is for data accessed less than once per 90 days, with storage costs higher than Archive and a 90-day minimum storage duration, which does not provide the lowest cost for long-term archival.

43
MCQhard

A company uses BigQuery for analytics. They notice high costs due to queries scanning large amounts of data. They want to reduce costs without sacrificing performance for urgent queries. Which approach is most cost-effective?

A.Use flat-rate pricing with reservations
B.Partition and cluster tables, and use BI Engine for acceleration
C.Use on-demand pricing with query caching
D.Use materialized views and limit query jobs to interactive priority
AnswerB

Partitioning and clustering limit the data scanned, and BI Engine provides fast in-memory analysis for critical queries without scanning.

Why this answer

B is correct because partitioning and clustering reduce the amount of data scanned per query, and BI Engine accelerates query performance, reducing cost without sacrificing speed for urgent queries. A is wrong: flat-rate pricing does not reduce data scanned; it's a pricing model that can be wasteful if not fully utilized. C is wrong: query caching only returns cached results for repeated queries, but doesn't reduce data scanned for new queries.

D is wrong: materialized views precompute results but incur storage costs and are not suitable for all ad-hoc queries; limiting to interactive priority doesn't reduce scanned data as effectively as partitioning/clustering.

44
MCQeasy

What is the primary benefit of using preemptible VMs?

A.Higher reliability.
B.Faster performance.
C.Better security.
D.Lower cost.
AnswerD

Preemptible VMs are significantly cheaper than regular VMs.

Why this answer

Preemptible VMs are Compute Engine instances that last a maximum of 24 hours and can be terminated at any time by Google. They offer a significantly lower price—up to 60-91% discount compared to standard VMs—making them ideal for batch jobs and fault-tolerant workloads where cost savings are the primary benefit.

Exam trap

Google Cloud often tests the misconception that preemptible VMs offer higher performance or reliability, but the exam trap is that candidates confuse the cost-saving benefit with other attributes like speed or availability, which are not improved.

How to eliminate wrong answers

Option A is wrong because preemptible VMs have no reliability guarantees; they can be terminated at any time, so they are less reliable than standard VMs. Option B is wrong because preemptible VMs use the same machine types and performance as standard VMs; there is no performance boost. Option C is wrong because preemptible VMs do not provide better security; they share the same security model as standard VMs and are not designed for security enhancements.

45
Matchingmedium

Match each cost optimization practice to its description.

Drag a concept onto its matching description — or click a concept then click the description.

Concepts
Matches

Discount for 1- or 3-year resource commitment

Automatic discounts for running instances most of month

Short-lived, low-cost instances for batch jobs

Adjusting machine type to match workload needs

Notifications when spending exceeds thresholds

Why these pairings

Common cost management techniques on Google Cloud include Committed Use Discounts (long-term commitment savings), Preemptible VMs (short-lived cheaper instances), Sustained Use Discounts (automatic monthly usage discounts), and Custom Machine Types (tailored VMs). The distractors swap definitions between related practices.

46
MCQhard

A company runs a critical application on Google Kubernetes Engine (GKE) with 3 nodes (e2-standard-4). To reduce costs, the team is considering right-sizing the nodes. The application is latency-sensitive and experiences periodic traffic spikes. What is the most cost-effective approach that maintains performance during spikes?

A.Use a single larger node (n2-standard-8) to reduce node count and network overhead.
B.Switch to 3 n2-standard-2 nodes to reduce vCPU and memory, and rely on horizontal pod autoscaling.
C.Create a node pool with smaller nodes (e2-standard-2) using preemptible VMs and enable cluster autoscaler.
D.Keep current node size but use committed use discounts for 1 year to reduce per-hour cost.
AnswerC

Preemptible VMs are cheaper, and autoscaler adds nodes during spikes, maintaining performance.

Why this answer

The most cost-effective approach because it uses smaller e2-standard-2 nodes with preemptible VMs, which are significantly cheaper than regular VMs, and combines this with the cluster autoscaler to automatically add nodes during traffic spikes. This ensures that the latency-sensitive application maintains performance by scaling out horizontally when needed, while minimizing baseline costs with smaller, cheaper nodes.

Exam trap

The trap here is that candidates often assume preemptible VMs are unsuitable for production or latency-sensitive workloads, but the cluster autoscaler mitigates the risk of VM termination by quickly replacing nodes, making this a valid cost-saving strategy for spike-tolerant applications.

How to eliminate wrong answers

Option A is wrong because using a single larger node (n2-standard-8) creates a single point of failure and does not leverage horizontal scaling; during spikes, the application may still suffer from resource contention on a single node, and network overhead is negligible in GKE. Option B is wrong because switching to 3 n2-standard-2 nodes reduces total vCPU and memory by 50%, and relying solely on horizontal pod autoscaling without cluster autoscaler means the node pool cannot grow during spikes, leading to pod scheduling failures and performance degradation. Option D is wrong because keeping the current node size and using committed use discounts only reduces per-hour cost by about 20-30% but does not address the goal of right-sizing to reduce costs; it maintains the same over-provisioned resources, which is less cost-effective than using smaller nodes with autoscaling.

47
MCQmedium

A company uses BigQuery flat-rate pricing with 1000 slots. During peak hours, queries are queued, but during off-peak, many slots are idle. What is the most cost-effective way to handle the idle slots?

A.Purchase additional slots to reduce queuing
B.Do nothing; idle slots are already paid for
C.Use flex slots to add capacity only during peak
D.Change to on-demand pricing to pay only for data scanned
AnswerC

Flex slots are short-term commitments that provide extra capacity when needed.

Why this answer

Flex slots allow you to add capacity temporarily during peak hours, avoiding the cost of idle slots during off-peak. Option A would increase idle slots and cost. Option B is wasteful because paying for idle slots is not cost-effective.

Option D may increase costs for heavy usage due to per-scan pricing.

48
MCQhard

A company uses Cloud Storage with standard storage class for all data. They want to automatically move data that has been accessed more than 30 days ago to a lower-cost storage class, and after 90 days to archive. What should they configure?

A.Lifecycle management rules.
B.Bucket lock.
C.Retention policy.
D.Object versioning.
AnswerA

Lifecycle management enables automated transitions to reduce costs.

Why this answer

Lifecycle management rules can automatically transition objects to different storage classes based on age or last access time.

49
MCQmedium

A company is using BigQuery for analytics and wants to control costs. They have many queries that scan large amounts of data. Which approach is most effective in reducing query costs?

A.Switch to flat-rate pricing to cap costs.
B.Partition tables by date and use partition pruning in queries.
C.Reserve BigQuery slots for dedicated capacity.
D.Use clustering to organize data within partitions.
AnswerB

Partitioning limits the data scanned, reducing query costs.

Why this answer

Partitioning tables by date and using partition pruning in queries directly reduces the amount of data scanned by BigQuery, which is the primary driver of on-demand query costs. By filtering on the partition column, BigQuery can skip entire partitions that do not match the query criteria, minimizing the bytes processed. This is the most effective cost-control measure because it addresses the root cause of high costs—excessive data scanning—without requiring a pricing model change or additional resource commitments.

Exam trap

Google Cloud often tests the misconception that clustering alone is sufficient for cost reduction, but clustering only optimizes data within a partition and cannot skip entire partitions, making partitioning the primary mechanism for cost control.

How to eliminate wrong answers

Option A is wrong because switching to flat-rate pricing caps the maximum cost but does not reduce the amount of data scanned; it simply changes the billing model from per-byte to a fixed monthly fee, which could be more expensive if usage is low or variable. Option C is wrong because reserving BigQuery slots for dedicated capacity provides predictable performance and cost but does not inherently reduce the amount of data scanned; it is a capacity-based pricing model that still charges for the slots regardless of query efficiency. Option D is wrong because clustering organizes data within partitions to improve query performance and reduce costs by limiting the data scanned within a partition, but it is secondary to partitioning; without partition pruning, clustering alone cannot skip entire partitions and is less effective at reducing overall data scanned.

50
MCQeasy

A startup runs a batch data processing job every night. The job processes large datasets and takes about 6 hours to complete. The job is designed to handle interruptions gracefully by saving checkpoint files to Cloud Storage every few minutes. The startup wants to minimize compute costs. The current setup uses a managed instance group with 10 n1-standard-4 VMs running for the entire 6-hour window. They are considering using preemptible VMs. However, they are concerned about cost stability and potential preemption. What should they do?

A.Use sole-tenant nodes to improve performance.
B.Use a mix of preemptible and regular VMs to ensure at least some progress if preempted.
C.Use preemptible VMs for all instances, as the job can resume from checkpoints.
D.Use regular VMs with committed use discounts for a 1-year term.
AnswerC

Preemptible VMs offer cost savings of 60-80% and are ideal for fault-tolerant batch jobs that can checkpoint progress.

Why this answer

The job is fault-tolerant and can resume from checkpoints, making preemptible VMs suitable and significantly cheaper. Option A is not relevant as sole-tenant nodes do not reduce cost. Option B adds unnecessary complexity and still uses regular VMs.

Option D requires a long-term commitment and is more expensive than preemptible VMs.

Exam trap

Candidates may think preemptible VMs are unreliable for critical jobs, but the checkpoint mechanism makes them viable here.

51
MCQhard

A company uses Cloud CDN to deliver content globally. They notice increasing egress costs. Which change will most effectively reduce egress costs?

A.Switch to a premium tier network for lower egress rates.
B.Enable gzip compression for all responses.
C.Use Cloud Armor to block malicious traffic.
D.Configure Cloud CDN to cache more content and increase cache hit ratio.
AnswerD

Higher cache hit ratio reduces the amount of data fetched from the origin, lowering egress costs.

Why this answer

Increasing the cache hit ratio reduces the number of requests that reach the origin server, which directly lowers the volume of data transferred from the origin to the CDN edge. Since egress costs are primarily driven by data served from the CDN edges to users, caching more content at the edge minimizes the need to fetch and serve data from the origin, thereby reducing overall egress traffic and associated costs.

Exam trap

The trap here is that candidates often confuse reducing data size (compression) with reducing data volume (caching), or assume that blocking traffic (Cloud Armor) is the primary cost-control mechanism, when in fact increasing cache efficiency is the most direct and effective method to lower egress costs in a CDN architecture.

How to eliminate wrong answers

Option A is wrong because switching to a premium tier network typically increases egress rates (higher performance, higher cost) and does not reduce egress costs; it may even increase them. Option B is wrong because enabling gzip compression reduces the size of responses, which can lower bandwidth usage, but it does not address the root cause of egress costs—the volume of data served from the CDN—and compression is often already applied by default or has limited impact on already-compressed content like images and video. Option C is wrong because Cloud Armor blocks malicious traffic at the edge, which can reduce some egress from attacks, but legitimate user traffic still generates egress costs; blocking malicious traffic does not significantly reduce overall egress costs for a globally distributed content delivery service.

52
MCQmedium

A mid-size company has multiple Google Cloud projects for different departments. The finance team wants to set up budget alerts to track spending across all projects. They have enabled billing export to BigQuery. The budget should trigger alerts when total cumulative spending exceeds 80% and 100% of the monthly budget of $10,000. The budget must be applied across all projects in the organization. They created a budget at the billing account level with amount $10,000, set alert thresholds at 80% and 100%, and added email recipients. However, after two weeks, spending in one project alone has exceeded $8,000 but no alert was triggered. What is the most likely cause?

A.The budget was set at the organization level, not billing account.
B.The budget was scoped to a single project instead of the billing account.
C.The budget thresholds were set as percentage of current spending not cumulative.
D.The budget amount includes credits or discounts.
AnswerB

A budget scoped to a single project only monitors that project's spending, missing spending from other projects.

Why this answer

The most likely cause is that the budget was scoped to a single project rather than the entire billing account (Option B). When a budget is scoped to a single project, it only tracks spending for that specific project. Since the high spending of $8,000 occurred in a different project, the budget did not detect it, and no alert was triggered.

Option A is incorrect because budgets at the organization level are not applicable for billing account budgets; budgets must be at the billing account level to cover all projects. Option C is incorrect because budget thresholds are set as percentages of the budget amount ($10,000), not as percentages of current spending. Option D is incorrect because the budget amount does not include credits or discounts; if it did, the actual spending might be higher than the budget amount, but that would not prevent alerts from triggering when the threshold is reached.

53
MCQhard

A team uses Cloud SQL for MySQL. They have read-heavy traffic and want to reduce costs. Which strategy is most effective?

A.Use read replicas to offload read queries.
B.Use committed use discounts.
C.Use High Availability with a standby instance.
D.Use vertical scaling to increase instance size.
AnswerA

Read replicas distribute reads, reducing primary load and enabling potential downsizing.

Why this answer

Using read replicas offloads read queries from the primary instance, allowing the primary to be downsized or use a lower-tier instance, reducing cost.

54
MCQeasy

Which GCP tool provides recommendations for rightsizing Compute Engine VMs?

A.Cloud Console Cost Table.
B.Cloud Monitoring.
C.Cloud Billing Reports.
D.Recommender.
AnswerD

Recommender provides rightsizing and other cost optimization recommendations.

Why this answer

The Recommender tool in GCP uses machine learning to analyze historical usage patterns and provides actionable recommendations, including rightsizing suggestions for Compute Engine VMs. It identifies underutilized VMs and suggests optimal machine types to reduce costs without compromising performance, making it the correct choice for this task.

Exam trap

The trap here is that candidates often confuse Cloud Monitoring's alerting capabilities with proactive recommendations, assuming that monitoring data alone provides rightsizing suggestions, but Recommender is the dedicated tool for that purpose.

How to eliminate wrong answers

Option A is wrong because Cloud Console Cost Table is not a GCP tool; it is a generic term and does not exist as a specific service for rightsizing recommendations. Option B is wrong because Cloud Monitoring focuses on collecting metrics, logs, and setting alerts, but it does not generate rightsizing recommendations; it provides data that could be used manually but lacks the automated analysis. Option C is wrong because Cloud Billing Reports provide cost breakdowns and usage trends, but they do not offer specific VM rightsizing suggestions; they are for historical cost analysis, not proactive optimization.

Ready to test yourself?

Try a timed practice session using only Optimizing performance and cost questions.