Question 52 of 890
mediumMultiple ChoiceObjective-mapped
Reduce Dataproc Costs Using Preemptible Virtual Machines
A company uses Cloud Dataproc to run nightly Spark ETL jobs that process about 500 GB of data each night. The jobs currently take 4 hours to complete. The company wants to reduce the runtime to under 2 hours to meet a new SLA. The cluster is configured with 10 worker nodes (n1-standard-4) and 1 master node (n1-standard-4). The jobs are CPU-bound and use only default settings. The cluster is deleted after each job and recreated. The data is stored in Cloud Storage. The company is open to increasing cost but wants the most cost-effective solution to meet the SLA. Which approach should they take?
Quick Answer
The answer is to increase the number of worker nodes to 20 and use preemptible VMs for half of them. This is correct because CPU-bound Spark jobs scale nearly linearly with additional cores, so doubling the worker count from 10 to 20 directly halves runtime, while substituting half the nodes with preemptible VMs achieves the most cost-effective solution by leveraging their significantly lower price. On the Google Professional Data Engineer exam, this scenario tests your understanding of dataproc cost optimization preemptible vms, specifically how to balance performance and budget for ephemeral, fault-tolerant workloads. A common trap is assuming you must avoid preemptible VMs entirely due to their short lifespan, but Spark’s resilience and the nightly batch nature of the job make them ideal here. Memory tip: for CPU-bound jobs, think “more cores, less cost” — double the workers, halve the price with preemptibles.
⚠ Common exam trap
Many candidates assume CPU-bound jobs require faster CPUs (Option D) or more memory (Option B), but horizontal scaling with preemptible VMs is the most cost-effective way to increase parallelism in Cloud Dataproc.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Increase the number of worker nodes to 20 and use preemptible VMs for half of them.
Adding more worker nodes (from 10 to 20) directly increases parallelism for CPU-bound Spark jobs, and using preemptible VMs for half of them reduces cost while still meeting the SLA. Since the job is CPU-bound and uses default settings, scaling horizontally with a mix of standard and preemptible VMs is the most cost-effective way to halve runtime, as Spark can efficiently distribute the workload across more cores.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Use a regional Cloud Storage bucket to improve read throughput.
Why it's wrong here
Not CPU-bound.
- ✗
Replace worker nodes with n1-highmem-16 instances to increase memory.
Why it's wrong here
Memory is not the bottleneck.
- ✓
Increase the number of worker nodes to 20 and use preemptible VMs for half of them.
Why this is correct
Doubles processing power cost-effectively.
- ✗
Change machine type to n2-standard-8 for all nodes.
Why it's wrong here
May be more expensive per core.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Same concept, more angles
1 more way this is tested on PDE
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. A data team uses Cloud Dataproc to run nightly Spark jobs. The job volume has increased, and the cluster is often underutilized during the day. They want to reduce costs while ensuring jobs can scale when needed. Which strategy should they adopt?
medium- A.Use preemptible workers for both primary and secondary nodes to minimize cost.
- B.Manually scale the cluster up before nightly jobs and down after.
- ✓ C.Use a cluster with a small number of primary workers and a large pool of preemptible workers, and enable autoscaling.
- D.Use custom machine types with local SSDs for primary workers to improve I/O.
Why C: It combines a small number of primary (non-preemptible) workers for reliability with a large pool of preemptible workers for cost-effective scaling, and enables autoscaling to dynamically adjust the cluster size based on workload. This minimizes cost during idle periods (preemptible instances are ~80% cheaper) while ensuring jobs can scale up quickly when needed, as autoscaling adds preemptible workers automatically. Preemptible workers are ideal for fault-tolerant Spark jobs that can handle node preemptions.
Last reviewed: Jun 11, 2026
This PDE practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the PDE exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.