GCP Flashcards
You have downloaded the SDK kit from Google and now would like to
manage containers on GKE with gcloud. What command would be typed to
install kubectl in the CLI?
A. Gcloud components install kubectl
B. Gcloud components kubectl install
C. Gcloud components install kubernetes
D. Gcloud components install components kubectl
A. gcloud components install kubectl
Explanation: Using gcloud is very important for this cloud engineer exam
around Kubernetes. The gcloud commands are what interact with GCP
resources that create and manage the clusters and then the kubectl, which is
the Kubernetes command line tool is used to run commands against
Kubernetes clusters on GKE.
A recent software update to your enterprises e-commerce website that is
running on Google Cloud has caused the website to crash for several hours.
Your CTO decides that all critical changes must now have a back-out/roll-
back plan. The website is deployed on hundreds of virtual machines (VMs),
and critical changes are frequent.
Which two actions should you take to implement the back-out/roll-back
plan??
A. Use managed instance groups with the “update-instances”
command when starting a rolling update
B. Enable object versioning on the website’s static data files stored
in Google Cloud Storage
C. Create a new instance template with applied fixes and roll out
via A/B test
D. Use unmanaged instance groups with the “update-instances”
command when starting a rolling update
Correct Answer(s): B. Processor
Explanation: Use managed instance groups to provide updates and object
versioning will ensure that you can get back to the previous stable version.
Your company uses a third-party monitoring solution for your
enterprise apps. You are using Kubernetes Engine for your container
deployments and would like to enable this internal monitoring app for
Kubernetes clusters. What would be the best approach? (Select One)
A. Deploy the monitoring pod as a DaemonSet.
B. Deploy the monitoring pod as a cluster
C. Deploy the monitoring extension for Stackdriver Trace
D. Deploy a solution from the Cloud Marketplace
Correct Answer(s): A. Deploy the monitoring pod as a DaemonSet.
Explanation: Many monitoring solutions use the Kubernetes DaemonSet
structure to deploy an agent on every cluster node. S Note that each tool has
its own software for cluster monitoring. Heapster is another option that could
also be used, Heapster is a bridge between a cluster and a storage designed to
collect the cluster metrics. Stackdriver is native to Google Cloud and
therefore the recommended approach by Google Cloud.
App Engine services are specified(designed) to be _________?
A. Regional
B. Global
C. Multi-regional
D. Zonal
Correct Answer(s): A. Regional
Explanation: App Engine is a regional service , which means the
infrastructure that runs your apps is located in a specific region. This region
cannot be moved nor migrated. It is managed by Google to be redundantly
available across all the zones within that region.
- The Monitoring agent, ________________, is based on the original
collectd system statistics collection daemon? (Select One)
A. Stackdriver-agent
B. Stackdriver-agent-collectd
C. Stackdriver-collectd
D. Stackdriver-statsd
Correct Answer(s): A. Stackdriver-agent
Explanation: The Stackdriver Monitoring agent is a collectd-based daemon
that gathers system and application metrics from virtual machine instances
and sends them to Stackdriver
Monitoring. cloud.google.com/monitoring/agent/
- You are currently deploying an application on a Kubernetes cluster.
Your aware that a Deployment’s rollout is triggered if and only if the
Deployment’s pod template is changed, for example if the labels or
container images of the template are updated. Other updates, such as scaling
the Deployment, do not trigger a rollout. What is the file name that would
need to be changed? (Select One)
A. .spectemplate.yaml
B. App.py
C. .template.yaml
D. .spec.template
Correct Answer(s): D. .spec.template is a deployment template.
Explanation: A Deployment’s rollout is triggered if and only if the
Deployment’s Pod template is changed.
https://kubernetes.io/docs/concepts/workloads/controllers/deployment/
- You are currently looking at your GCP platform with gcloud and
would like to list all the instances in GCP Compute Engine. What command
would you use? (Select One)
A. gcloud compute instances grep
B. gcloud grep compute instances
C. gcloud compute list instances
D. gcloud compute instances list
Correct Answer(s): D. gcloud compute instances list
Explanation: Review the gcloud documentation site for command syntax
https://cloud.google.com/sdk/gcloud/reference/compute/instances/list
- __________________is a unified programming model and also a
managed service for developing and executing a wide range of data
processing patterns including ETL, batch computation, and continuous
computation. What is the service? (Select One)
A. Cloud Datalab
B. Cloud Dataflow
C. Cloud Dataproc
D. Cloud Spanner
Correct Answer(s): B. Cloud Dataflow
Explanation: Cloud Dataflow is a unified programming model and a managed
service for developing and executing a wide range of data processing patterns
including ETL, batch computation, and continuous computation. The
challenge with a lot of the GCP services is that they sound the same or have
the same prefix which can be confusing.
https://cloud.google.com/sdk/gcloud/reference/dataflow/
- Your considering placing your Infrastructure as code processes on Cloud
Deployment Manager. What would be a risk of doing this? (Select One)
A. Cloud Deployment Manager requires a Google APIs service
account to run.
B. Cloud Deployment Manager APIs could be deprecated in the
future.
C. Cloud Deployment Manager can be used to permanently delete
cloud resources.
D. Cloud Deployment Manager takes some training to use.
Correct Answer(s): B. Cloud Deployment Manager.
Explanation: APIs could be deprecated in the future.
APIs of course take maintenance. Other choices would likely not be a risk.
10 You are currently reviewing your project in GCP using gcloud. You
would like to confirm what the DNS related info is for a project. What is the
command to do this? Select One
(Select One)
A. gcloud dns project-info describe
B. gcloud dns project-info list
C. gcloud dns project-info show
D. gcloud dns project-info grep
Correct Answer(s): A. gcloud dns project-info describe
Explanation: gcloud commands need to be memorized. The easy way to
rule out two answers is generally to look at the service which should come
after gcloud. If the answer is flag related, then we need to memorize in most
cases. https://cloud.google.com/sdk/gcloud/reference/dns/project-info/
- You are evaluating new GCP services and would like to use tools to
help you evaluate the costs of using GCP. What are two tools available from
GCP to help analyse costs. (Select Two)
A. Pricing Calculator
B. ROI Calculator
C. TCO Tool
D. Cost Optimization Tool
Correct Answer(s): A and C: Pricing Calculator and TCO Tool
Explanation. For this exam. Expect several questions on pricing Bigtable and
Storage. You can also take advantage of some tools to help you evaluate the
costs of using GCP. The pricing calculator provides a quick and easy way to
estimate what your GCP usage will look like. You can provide details about
the services you want to use, such as the number of Compute Engine
instances, persistent disks and their sizes, and so on, and then see a pricing
estimate.
https://cloud.google.com/products/calculator
The Total Cost of Ownership (TCO) Tool evaluates the relative costs for
running your compute load in the cloud and provides a financial estimate.
The tool provides several inputs for cost modelling, which you can adjust,
and then compares estimated costs on GCP and AWS. This tool does not
model all components of a typical application, such as storage and
networking.
https://inthecloud.withgoogle.com/tco-assessment-19/form.html
- You would like to create a new container repository with Cloud Source
Repositories using gcloud. What would be the command to create a repo
called “devops” (Select One)
A. gcloud source repo create devops
B. gcloud source repos create devops
C. gcloud create source repos “devops”
D. gcloud create source repos devops
Correct Answer(s): B. gcloud source repos create devops
Explanation. Note on the cloud engineer exam. There were a few questions
that required exact syntax knowledge for devops services such as Cloud
Build, Cloud Source Repo and Container Registry
gcloud source repo create devops
https://cloud.google.com/source-repositories/docs/creating-an-empty-
repository
Your currently ready to deploy some Cloud Deployment Manager
templates and you will need to ensure specific requirements (“explicit”) exists
before the templates deploy. What would be the option you would add to
your templates or configuration files? (Select One)
A. dependsOn
B. properties
C. variables
D. deployON
Correct Answer(s): A. dependsOn
Explanation. “dependsOn” You can specify these dependencies using the
dependsOn option in your configuration files or templates. When you add the
dependsOn option for a resource, Deployment Manager creates or updates the
dependencies before creating or updating the resource.
https://cloud.google.com/deployment-manager/docs/configuration/create-
explicit-dependencies
- By default you can create up to _______ networks per project. (Select
One)
A. 10
B. 100
C. 5
D. 50
Correct Answer(s): C. 5
Explanation. By default ,the limit is 5 per project. You can contact support to
have this adjusted as needed. The exam has a few trivia around projects and
quotas.
https://cloud.google.com/vpc/docs/using-vpc
- You would like to deploy a LAMP stack for your development team.
The only issue is you’re not sure how to configure this LAMP stack. You
would like to use a solution that has readymade templates to deploy. What
GCP service could you use (Select One)
A. Cloud Deployment Manager
B. Cloud Marketplace
C. Cloud Endure
D. Cloud DataFlow
Correct Answer(s): B. Cloud Marketplace
Explanation: Google Cloud Marketplace formerly Cloud Launcher offers
ready-to-go development stacks, solutions, and services to accelerate
development, so you spend less time installing and more time developing.
https://cloud.google.com/launcher/
- You would like to create a file structure for Cloud Storage that can be
mounted to Compute Engine. What would be the best option? (Select One)
A. Fuse Tool
B. Samba
C. NFS
D. Use Filestore
Explanation: You can use the Google Cloud Storage FUSE tool to mount a
Cloud Storage bucket to your Compute Engine instance. The mounted bucket
behaves similarly to a persistent disk even though Cloud Storage buckets are
object storage. To learn how to mount a Cloud Storage bucket on your
instance, read Using Cloud Storage FUSE.
https://cloud.google.com/compute/docs/disks/gcs-buckets
- The__________ Tier delivers traffic over Google’s well-provisioned,
low latency, highly reliable global network. (Select One)
A. Standard
B. Premium
C. Cloud VPN
D. Cloud Interconnect
Correct Answer(s): B. Premium
Explanation: The Premium Tier delivers traffic over Google’s well-
provisioned, low latency, highly reliable global network.
https://cloud.google.com/network-tiers/
- You are designing a CD Pipeline and would like to have your source
code hosted on GKE, Build Automation and Artifact Management with
GCP Services. Your currently using Spinnaker for your code deployment.
A. Cloud Source Repositories, Cloud Build, GKE
B. Cloud Build, Cloud Source Repositories, Container
Registry
C. Cloud Source Repositories, Cloud Build, Container
Registry
D. Kubernetes Engine, Cloud Source Repositories, Container
Registry
A. Cloud Source Repositories, Cloud Build, GKE
B. Cloud Build, Cloud Source Repositories, Container
Registry
C. Cloud Source Repositories, Cloud Build, Container
Registry
D. Kubernetes Engine, Cloud Source Repositories, Container
Registry
- You have just started your cluster and deployed your pods. You now
need to view all the running pods. What is the proper CLI syntax to
accomplish this task? (Select One)
A. kubectl get pods
B. kubectl list pods
C. gcloud get pods
D. gcloud list pods
Correct Answer(s): A: kubectl get pods
Explanation: The command syntax to inspect pods is the same as you would
use for your on-premises deployments. kubectl get pods
- You have been contacted by the enterprise support team which has told
you there have reports of significant latency at specific times for an
application running on GCP. They would like you to review the issue and
provide them insight into why the application is latent at specific times?
What Google Cloud service could you use to inspect latency data that has
been collected in near real time? (Select One)
A. Stackdriver Debug
B. Stackdriver Trace
C. VPC Trace Logs
D. Stackdriver Profiler
Correct Answer(s): A: Stackdriver Trace (Cloud Trace)
Explanation: Cloud Trace formerly Stackdriver Trace is a distributed tracing
system that collects latency data from your applications and displays it in the
Google Cloud Console. You can track how requests propagate through your
application and receive detailed near real-time performance insights. Cloud
Trace automatically analyses all your application’s traces to generate in-depth
latency reports to surface performance degradations and can capture traces
from all your VMs, containers, or App Engine projects.