🔥 40% Off Crucial Exams Memberships — Deal ends today!

27 minutes, 18 seconds remaining!

GCP Associate Cloud Engineer Practice Question

Your team launched a Compute Engine VM two days ago but kept the default service account. The application running on the VM now needs to read objects from a Cloud Storage bucket. You have already created a new user-managed service account in the same project and granted that account the Storage Object Viewer role on the bucket. You want the running VM to begin using the new service account with minimal interruption and without changing the VM's external IP address. What should you do?

  • Run gcloud compute instances set-service-account INSTANCE --service-account NEW_SA_EMAIL while the VM is running; no restart is needed.

  • Generate a JSON key for the new service account, copy the key file to the VM, and set the GOOGLE_APPLICATION_CREDENTIALS environment variable.

  • Create an instance template using the new service account, then recreate the VM from that template and delete the original instance.

  • Add the Storage Object Viewer role to the VM's existing default Compute Engine service account; no further action is required.

GCP Associate Cloud Engineer
Configuring access and security
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot