Uploading Files to Cloud Storage for Dataproc
Short answer
A Use the gsutil cp command to upload local files to a Google Cloud Storage bucket for consumption by Dataproc.
Question
DataProc Hadoop cluster in a GCP environment.
Which command should you use?
Key Takeaways
Tests the distinction between Cloud Storage CLI tools (gsutil/gcloud storage) and invalid or cluster-specific commands (hadoop fs, gcloud dataproc).
Identifies the correct command to upload local files to Google Cloud Storage for a Dataproc migration. The gsutil cp command is the standard tool for local-to-GCS file transfers.
Common mistake: Choosing B because of familiarity with gcloud, but gcloud cp is invalid; the newer equivalent is gcloud storage cp, not gcloud cp.
Expert Analysis
Cloud Storage vs. Hadoop CLI Boundary The core of this question tests the boundary between general-purpose Cloud Storage transfer tools and Hadoop/Dataproc-specific commands. The task is explicitly to upload files from an on-premises VM to Cloud Storage, not to move data within a Hadoop cluster. Therefore, the command must be a Cloud Storage CLI tool, not a Hadoop command.
Evaluating the Options Option A uses gsutil cp, which is the established command-line tool for interacting with Google Cloud Storage. It handles local-to-cloud uploads efficiently. Option C uses hadoop fs cp, which is meant for HDFS operations within a Hadoop cluster, not direct local-to-cloud uploads from a standard VM. Option D uses gcloud dataproc cp, which is a non-existent command. Option B uses gcloud cp, which is also invalid. As noted in community feedback, Google has introduced gcloud storage cp as a modern alternative to gsutil, but gcloud cp by itself does not exist. Thus, Option A is the only syntactically and functionally correct choice.
The Dataproc Distraction The mention of Dataproc is a distractor designed to lure candidates toward Hadoop-specific commands (Option C) or Dataproc-specific commands (Option D). Dataproc natively uses Cloud Storage (via the GCS connector) instead of HDFS, meaning data must land in Cloud Storage first before the cluster can consume it. The upload step from on-premises relies entirely on Cloud Storage tooling.
Official Reference
- https://cloud.google.com/storage/docs/gsutil/commands/cp
- https://cloud.google.com/sdk/gcloud/reference/storage/cp
These links open the official vendor documentation in a new tab.
Exam Strategy
When asked to transfer files to or from Google Cloud Storage, immediately look for gsutil or gcloud storage commands. Be wary of gcloud cp as it is an invalid command. If the destination prefix is gs://, it is a Cloud Storage operation, ruling out hadoop fs commands which require a Hadoop environment.
Community Votes
90% of anonymous learners picked answer A. Votes are pick records left by other test-takers — they are not the verified answer.
Discussion 31 contributions
Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.
From public community threads 30 of 31
-
i896ii 👍 5Took the exam 2 weeks and got pass, however, NOT A SINGLE question is from here! Although it is still good for practice purpose, DO NOT just remember these questions to take the exam. -- My comment above is still waiting approval after two weeks, it seems someone doesn't want it to be published.
-
Jigglypuff09 👍 3 Answered BAnyone took exam recently, what percent of questions came from a public community thread?
-
syu31svc 👍 3Cloud Storage is the key here so answer is A
-
mobius_z 👍 2Took the exam two days ago, only 4 of the questions from this set appeared in the actual exam, remaining 56 were new questions. Even after the June 2nd update, I don't see any of the new questions here.
-
SuperDevops 👍 2The exam is totally different from the one presented in the dump, it proves TOTALLY DIFFERENT. Please update the questions with the original exam!!
Show 25 more comments
-
mlyu 👍 2Ans:A https://cloud.google.com/storage/docs/uploading-objects
-
Daywa1k3r 👍 2There was a lot of GKE especially with istio.
-
runrajarun 👍 2any possibility to have all DevOps questions?
-
1234567J 👍 2why do you lie
-
JuanitoNN 👍 1You are running an application on Compute Engine and collecting logs through Stackdriver. You discover that some personally identifiable information (Pll) is leaking into certain log entry fields. All Pll entries begin with the text userinfo. You want to capture these log entries in a secure location for later review and prevent them from leaking to Stackdriver Logging. What should you do? "A. Create a basic log filter matching userinfo, and then configure a log export in the Stackdriver console with Cloud Storage as a sink. B. Use a Fluentd filter plugin with the Stackdriver Agent to remove log entries containing userinfo, and then copy the entries to a Cloud Storage bucket. C. Create an advanced log filter matching userinfo, configure a log export in the Stackdriver console with Cloud Storage as a sink, and then configure a tog exclusion with userinfo as a filter. D. Use a Fluentd filter plugin with the Stackdriver Agent to remove log entries containing userinfo, create an advanced log filter matching userinfo, and then configure a log export in the Stackdriver console with Cloud Storage as a sink."
-
JuanitoNN 👍 1Your product is currently deployed in three Google Cloud Platform (GCP) zones with your users divided between the zones. You can fail over from one zone to another, but it causes a 10-minute service disruption for the affected users. You typically experience a database failure once per quarter and can detect it within five minutes. You are cataloging the reliability risks of a new real-time chat feature for your product. You catalog the following information for each risk. The chat feature requires a new database system that takes twice as long to successfully fail over between zones. You want to account for the risk of the new database failing in one zone. What would be the values for the risk of database failover with the new system? A. MTTD: 5 MTTR: 10 MTBF: 90 Impact: 33% B. MTTD:5 MTTR: 20 MTBF: 90 Impact: 33% C. MTTD:5 MTTR: 10 MTBF: 90 Impact 50% D. MTTD:5 MTTR: 20 MTBF: 90 Impact: 50%
-
Hila_Sh 👍 1 Answered AA. gsutil cp [LOCAL_OBJECT] gs://[DESTINATION_BUCKET_NAME]/ gsutil is the correct tool because: It's the dedicated command-line tool for Google Cloud Storage operations Specifically designed for file and bucket management in GCS Supports efficient file transfer between local systems and Cloud Storage Provides reliable upload capabilities with automatic retry mechanisms The command structure: gsutil cp [LOCAL_OBJECT] gs://[DESTINATION_BUCKET_NAME]/ cp: Copy command [LOCAL_OBJECT]: Source file path gs://: Protocol identifier for Google Cloud Storage [DESTINATION_BUCKET_NAME]: Target bucket name
-
runrajarun 👍 1Q. Devops You support the backend of a mobile phone game that runs on a Google Kubernetes Engine (GKE) cluster. The application is serving HTTP requests from users. You need to implement a solution that will reduce the network cost. What should you do? "A. Configure the VPC as a Shared VPC Host project. B. Configure your network services on the Standard Tier. C. Configure your Kubernetes cluster as a Private Cluster. D. Configure a Google Cloud HTTP Load Balancer as Ingress." ans : B
-
JuanitoNN 👍 1Q. Devops You support the backend of a mobile phone game that runs on a Google Kubernetes Engine (GKE) cluster. The application is serving HTTP requests from users. You need to implement a solution that will reduce the network cost. What should you do? "A. Configure the VPC as a Shared VPC Host project. B. Configure your network services on the Standard Tier. C. Configure your Kubernetes cluster as a Private Cluster. D. Configure a Google Cloud HTTP Load Balancer as Ingress."
-
www_certifiedumps_com_google 👍 1 Answered AA. gsutil cp [LOCAL_OBJECT] gs://[DESTINATION_BUCKET_NAME]/ This command is used to copy files from local storage to Google Cloud Storage. It’s the correct option for uploading data as part of a migration process that will be consumed by Cloud Dataproc.
-
InsaneKelso 👍 1 Answered AA is the only valid option, however if B had contained the component storage (gcloud storage cp [LOCAL_OBJECT] gs://[DESTINATION_BUCKET_NAME]/) then it would have been the correct choice seeing how gsutil is considered legacy
-
Edgar0123 👍 1As updates to the Google Cloud SDK, the
gcloudtool now includes astoragecommand group that allows you to interact with Google Cloud Storage (GCS) similarly to how you would withgsutilcommand -
wanrltw 👍 1 Answered AAnswer: A Cloud Storage => gsutil. Doesn't matter how the files are going to be consumed, the task is to upload them.
-
runrajarun 👍 1Standard tier is less cost compared to http load balance ingress and kubernates cluster.
-
atoledo 👍 1 Answered Agsutil cp [LOCAL_OBJECT] gs://[DESTINATION_BUCKET_NAME]/
-
looseboy 👍 1My comment is still waiting approval too.
-
chithra1990 👍 1is this question set updated ?
-
yuchun 👍 1cloud storage command: gsutil
-
JuanitoNN 👍 1Hello, why is b, any reason?
-
blackshuai 👍 1A is correct answer
-
__rajan__ 👍 1 Answered AI would go with A.
-
ds0312 👍 1Correct answer - A
-
TNT87 👍 1B is the answer
-
Nandak217 👍 1A is correct
-
sanjay8055 👍 1 Answered AAnswer is A
Reader comments & corrections
No reader corrections yet — spotted an error or have a note? Share it below.
Related Analysis
Practice All PCD Questions
Access 84 questions with complete answers and detailed explanations.
View Full PCD Practice Test →