πŸ”

PCA β€” questions

Page 4 of 17 Β· 337 total questions.

Topic 1 Β· Question 61

The development team has provided you with a Kubernetes Deployment file. You have no infrastructure yet and need to deploy the application. What should you do?

  • AUse gcloud to create a Kubernetes cluster. Use Deployment Manager to create the deployment.
  • BUse gcloud to create a Kubernetes cluster. Use kubectl to create the deployment. (correct answer)
  • CUse kubectl to create a Kubernetes cluster. Use Deployment Manager to create the deployment.
  • DUse kubectl to create a Kubernetes cluster. Use kubectl to create the deployment.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use gcloud to create a Kubernetes cluster. Use kubectl to create the deployment.

Topic 1 Β· Question 62

You need to evaluate your team readiness for a new GCP project. You must perform the evaluation and create a skills gap plan which incorporates the business goal of cost optimization. Your team has deployed two GCP projects successfully to date. What should you do?

  • AAllocate budget for team training. Set a deadline for the new GCP project.
  • BAllocate budget for team training. Create a roadmap for your team to achieve Google Cloud certification based on job role. (correct answer)
  • CAllocate budget to hire skilled external consultants. Set a deadline for the new GCP project.
  • DAllocate budget to hire skilled external consultants. Create a roadmap for your team to achieve Google Cloud certification based on job role.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Allocate budget for team training. Create a roadmap for your team to achieve Google Cloud certification based on job role.

Topic 1 Β· Question 63

You are designing an application for use only during business hours. For the minimum viable product release, you'd like to use a managed product that automatically `scales to zero` so you don't incur costs when there is no activity. Which primary compute resource should you choose?

  • ACloud Functions (correct answer)
  • BCompute Engine
  • CGoogle Kubernetes Engine
  • DAppEngine flexible environment
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Cloud Functions

Explanation

Cloud Functions runs event-driven code without managing servers and scales automatically.

Topic 1 Β· Question 64

You are creating an App Engine application that uses Cloud Datastore as its persistence layer. You need to retrieve several root entities for which you have the identifiers. You want to minimize the overhead in operations performed by Cloud Datastore. What should you do?

  • ACreate the Key object for each Entity and run a batch get operation (correct answer)
  • BCreate the Key object for each Entity and run multiple get operations, one operation for each entity
  • CUse the identifiers to create a query filter and run a batch query operation
  • DUse the identifiers to create a query filter and run multiple query operations, one operation for each entity
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Create the Key object for each Entity and run a batch get operation

Explanation

Google Cloud Batch schedules and runs batch jobs at scale without managing infrastructure.

Topic 1 Β· Question 65

You need to upload files from your on-premises environment to Cloud Storage. You want the files to be encrypted on Cloud Storage using customer-supplied encryption keys. What should you do?

  • ASupply the encryption key in a .boto configuration file. Use gsutil to upload the files. (correct answer)
  • BSupply the encryption key using gcloud config. Use gsutil to upload the files to that bucket.
  • CUse gsutil to upload the files, and use the flag --encryption-key to supply the encryption key.
  • DUse gsutil to create a bucket, and use the flag --encryption-key to supply the encryption key. Use gsutil to upload the files to that bucket.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Supply the encryption key in a.boto configuration file. Use gsutil to upload the files.

Topic 1 Β· Question 66

Your customer wants to capture multiple GBs of aggregate real-time key performance indicators (KPIs) from their game servers running on Google Cloud Platform and monitor the KPIs with low latency. How should they capture the KPIs?

  • AStore time-series data from the game servers in Google Bigtable, and view it using Google Data Studio.
  • BOutput custom metrics to Stackdriver from the game servers, and create a Dashboard in Stackdriver Monitoring Console to view them. (correct answer)
  • CSchedule BigQuery load jobs to ingest analytics files uploaded to Cloud Storage every ten minutes, and visualize the results in Google Data Studio.
  • DInsert the KPIs into Cloud Datastore entities, and run ad hoc analysis and visualizations of them in Cloud Datalab.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Output custom metrics to Stackdriver from the game servers, and create a Dashboard in Stackdriver Monitoring Console to view them.

Explanation

Cloud Operations (formerly Stackdriver) provides monitoring, logging, and tracing for reliability. This option meets the real-time / low-latency performance requirement.

Topic 1 Β· Question 67

You have a Python web application with many dependencies that requires 0.1 CPU cores and 128 MB of memory to operate in production. You want to monitor and maximize machine utilization. You also want to reliably deploy new versions of the application. Which set of steps should you take?

  • APerform the following: 1. Create a managed instance group with f1-micro type machines. 2. Use a startup script to clone the repository, check out the production branch, install the dependencies, and start the Python app. 3. Restart the instances to automatically deploy new production releases.
  • BPerform the following: 1. Create a managed instance group with n1-standard-1 type machines. 2. Build a Compute Engine image from the production branch that contains all of the dependencies and automatically starts the Python app. 3. Rebuild the Compute Engine image, and update the instance template to deploy new production releases.
  • CPerform the following: 1. Create a Google Kubernetes Engine (GKE) cluster with n1-standard-1 type machines. 2. Build a Docker image from the production branch with all of the dependencies, and tag it with the version number. 3. Create a Kubernetes Deployment with the imagePullPolicy set to 'IfNotPresent' in the staging namespace, and then promote it to the production namespace after testing. (correct answer)
  • DPerform the following: 1. Create a GKE cluster with n1-standard-4 type machines. 2. Build a Docker image from the master branch with all of the dependencies, and tag it with 'latest'. 3. Create a Kubernetes Deployment in the default namespace with the imagePullPolicy set to 'Always'. Restart the pods to automatically deploy new production releases.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Perform the following: 1. Create a Google Kubernetes Engine (GKE) cluster with n1-standard-1 type machines. 2. Build a Docker image from the production branch with all of the dependencies, and tag it with the version...

Explanation

Google Kubernetes Engine runs managed Kubernetes for containerized, portable workloads. Google Kubernetes Engine runs managed Kubernetes for containerized workloads.

Topic 1 Β· Question 68

Your company wants to start using Google Cloud resources but wants to retain their on-premises Active Directory domain controller for identity management. What should you do?

  • AUse the Admin Directory API to authenticate against the Active Directory domain controller.
  • BUse Google Cloud Directory Sync to synchronize Active Directory usernames with cloud identities and configure SAML SSO. (correct answer)
  • CUse Cloud Identity-Aware Proxy configured to use the on-premises Active Directory domain controller as an identity provider.
  • DUse Compute Engine to create an Active Directory (AD) domain controller that is a replica of the on-premises AD domain controller using Google Cloud Directory Sync.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use Google Cloud Directory Sync to synchronize Active Directory usernames with cloud identities and configure SAML SSO.

Topic 1 Β· Question 69

You are running a cluster on Kubernetes Engine (GKE) to serve a web application. Users are reporting that a specific part of the application is not responding anymore. You notice that all pods of your deployment keep restarting after 2 seconds. The application writes logs to standard output. You want to inspect the logs to find the cause of the issue. Which approach can you take?

  • AReview the Stackdriver logs for each Compute Engine instance that is serving as a node in the cluster.
  • BReview the Stackdriver logs for the specific GKE container that is serving the unresponsive part of the application. (correct answer)
  • CConnect to the cluster using gcloud credentials and connect to a container in one of the pods to read the logs.
  • DReview the Serial Port logs for each Compute Engine instance that is serving as a node in the cluster.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Review the Stackdriver logs for the specific GKE container that is serving the unresponsive part of the application.

Explanation

Google Kubernetes Engine runs managed Kubernetes for containerized, portable workloads. Cloud Operations (formerly Stackdriver) provides monitoring, logging, and tracing for reliability.

Topic 1 Β· Question 70

You are using a single Cloud SQL instance to serve your application from a specific zone. You want to introduce high availability. What should you do?

  • ACreate a read replica instance in a different region
  • BCreate a failover replica instance in a different region
  • CCreate a read replica instance in the same region, but in a different zone
  • DCreate a failover replica instance in the same region, but in a different zone (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Create a failover replica instance in the same region, but in a different zone.

Topic 1 Β· Question 71

Your company is running a stateless application on a Compute Engine instance. The application is used heavily during regular business hours and lightly outside of business hours. Users are reporting that the application is slow during peak hours. You need to optimize the application's performance. What should you do?

  • ACreate a snapshot of the existing disk. Create an instance template from the snapshot. Create an autoscaled managed instance group from the instance template.
  • BCreate a snapshot of the existing disk. Create a custom image from the snapshot. Create an autoscaled managed instance group from the custom image.
  • CCreate a custom image from the existing disk. Create an instance template from the custom image. Create an autoscaled managed instance group from the instance template. (correct answer)
  • DCreate an instance template from the existing disk. Create a custom image from the instance template. Create an autoscaled managed instance group from the custom image.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Create a custom image from the existing disk. Create an instance template from the custom image. Create an autoscaled managed instance group from the instance template.

Explanation

A managed instance group provides autoscaling, autohealing, and rolling updates for VMs.

Topic 1 Β· Question 72

Your web application has several VM instances running within a VPC. You want to restrict communications between instances to only the paths and ports you authorize, but you don't want to rely on static IP addresses or subnets because the app can autoscale. How should you restrict communications?

  • AUse separate VPCs to restrict traffic
  • BUse firewall rules based on network tags attached to the compute instances (correct answer)
  • CUse Cloud DNS and only allow connections from authorized hostnames
  • DUse service accounts and configure the web application to authorize particular service accounts to have access
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use firewall rules based on network tags attached to the compute instances.

Topic 1 Β· Question 73

You are using Cloud SQL as the database backend for a large CRM deployment. You want to scale as usage increases and ensure that you don't run out of storage, maintain 75% CPU usage cores, and keep replication lag below 60 seconds. What are the correct steps to meet your requirements?

  • A1. Enable automatic storage increase for the instance. 2. Create a Stackdriver alert when CPU usage exceeds 75%, and change the instance type to reduce CPU usage. 3. Create a Stackdriver alert for replication lag, and shard the database to reduce replication time. (correct answer)
  • B1. Enable automatic storage increase for the instance. 2. Change the instance type to a 32-core machine type to keep CPU usage below 75%. 3. Create a Stackdriver alert for replication lag, and deploy memcache to reduce load on the master.
  • C1. Create a Stackdriver alert when storage exceeds 75%, and increase the available storage on the instance to create more space. 2. Deploy memcached to reduce CPU load. 3. Change the instance type to a 32-core machine type to reduce replication lag.
  • D1. Create a Stackdriver alert when storage exceeds 75%, and increase the available storage on the instance to create more space. 2. Deploy memcached to reduce CPU load. 3. Create a Stackdriver alert for replication lag, and change the instance type to a 32-core machine type to reduce replication lag.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: 1. Enable automatic storage increase for the instance. 2. Create a Stackdriver alert when CPU usage exceeds 75%, and change the instance type to reduce CPU usage. 3. Create a Stackdriver alert for replication lag, and...

Explanation

Cloud Operations (formerly Stackdriver) provides monitoring, logging, and tracing for reliability.

Topic 1 Β· Question 74

You are tasked with building an online analytical processing (OLAP) marketing analytics and reporting tool. This requires a relational database that can operate on hundreds of terabytes of data. What is the Google-recommended tool for such applications?

  • ACloud Spanner, because it is globally distributed
  • BCloud SQL, because it is a fully managed relational database
  • CCloud Firestore, because it offers real-time synchronization across devices
  • DBigQuery, because it is designed for large-scale processing of tabular data (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: BigQuery, because it is designed for large-scale processing of tabular data

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage.

Topic 1 Β· Question 75

You have deployed an application to Google Kubernetes Engine (GKE), and are using the Cloud SQL proxy container to make the Cloud SQL database available to the services running on Kubernetes. You are notified that the application is reporting database connection issues. Your company policies require a post- mortem. What should you do?

  • AUse gcloud sql instances restart.
  • BValidate that the Service Account used by the Cloud SQL proxy container still has the Cloud Build Editor role.
  • CIn the GCP Console, navigate to Stackdriver Logging. Consult logs for (GKE) and Cloud SQL. (correct answer)
  • DIn the GCP Console, navigate to Cloud SQL. Restore the latest backup. Use kubectl to restart all pods.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: In the GCP Console, navigate to Stackdriver Logging. Consult logs for (GKE) and Cloud SQL.

Explanation

Google Kubernetes Engine runs managed Kubernetes for containerized, portable workloads. Cloud SQL is a managed relational database (MySQL/PostgreSQL/SQL Server) that handles patching, backups, and failover. Cloud Operations (formerly Stackdriver) provides monitoring, logging, and tracing for reliability.

Topic 1 Β· Question 76

Your company pushes batches of sensitive transaction data from its application server VMs to Cloud Pub/Sub for processing and storage. What is the Google- recommended way for your application to authenticate to the required Google Cloud services?

  • AEnsure that VM service accounts are granted the appropriate Cloud Pub/Sub IAM roles. (correct answer)
  • BEnsure that VM service accounts do not have access to Cloud Pub/Sub, and use VM access scopes to grant the appropriate Cloud Pub/Sub IAM roles.
  • CGenerate an OAuth2 access token for accessing Cloud Pub/Sub, encrypt it, and store it in Cloud Storage for access from each VM.
  • DCreate a gateway to Cloud Pub/Sub using a Cloud Function, and grant the Cloud Function service account the appropriate Cloud Pub/Sub IAM roles.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Ensure that VM service accounts are granted the appropriate Cloud Pub/Sub IAM roles.

Explanation

Pub/Sub is a serverless, global messaging service that decouples services and ingests high-volume event streams. A service account provides an identity for workloads to access Google Cloud APIs securely. Cloud IAM grants fine-grained, least-privilege access to Google Cloud resources.

Topic 1 Β· Question 77

You want to establish a Compute Engine application in a single VPC across two regions. The application must communicate over VPN to an on-premises network. How should you deploy the VPN?

  • AUse VPC Network Peering between the VPC and the on-premises network.
  • BExpose the VPC to the on-premises network using IAM and VPC Sharing.
  • CCreate a global Cloud VPN Gateway with VPN tunnels from each region to the on-premises peer gateway.
  • DDeploy Cloud VPN Gateway in each region. Ensure that each region has at least one VPN tunnel to the on-premises peer gateway. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Deploy Cloud VPN Gateway in each region. Ensure that each region has at least one VPN tunnel to the on-premises peer gateway.

Explanation

Cloud VPN provides encrypted IPsec connectivity between on premises and a VPC.

Topic 1 Β· Question 78

Your applications will be writing their logs to BigQuery for analysis. Each application should have its own table. Any logs older than 45 days should be removed. You want to optimize storage and follow Google-recommended practices. What should you do?

  • AConfigure the expiration time for your tables at 45 days
  • BMake the tables time-partitioned, and configure the partition expiration at 45 days (correct answer)
  • CRely on BigQuery's default behavior to prune application logs older than 45 days
  • DCreate a script that uses the BigQuery command line tool (bq) to remove records older than 45 days
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Make the tables time-partitioned, and configure the partition expiration at 45 days.

Topic 1 Β· Question 79

You want your Google Kubernetes Engine cluster to automatically add or remove nodes based on CPU load. What should you do?

  • AConfigure a HorizontalPodAutoscaler with a target CPU usage. Enable the Cluster Autoscaler from the GCP Console. (correct answer)
  • BConfigure a HorizontalPodAutoscaler with a target CPU usage. Enable autoscaling on the managed instance group for the cluster using the gcloud command.
  • CCreate a deployment and set the maxUnavailable and maxSurge properties. Enable the Cluster Autoscaler using the gcloud command.
  • DCreate a deployment and set the maxUnavailable and maxSurge properties. Enable autoscaling on the cluster managed instance group from the GCP Console.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Configure a HorizontalPodAutoscaler with a target CPU usage. Enable the Cluster Autoscaler from the GCP Console.

Topic 1 Β· Question 80

You need to develop procedures to verify resilience of disaster recovery for remote recovery using GCP. Your production environment is hosted on-premises. You need to establish a secure, redundant connection between your on-premises network and the GCP network. What should you do?

  • AVerify that Dedicated Interconnect can replicate files to GCP. Verify that direct peering can establish a secure connection between your networks if Dedicated Interconnect fails.
  • BVerify that Dedicated Interconnect can replicate files to GCP. Verify that Cloud VPN can establish a secure connection between your networks if Dedicated Interconnect fails. (correct answer)
  • CVerify that the Transfer Appliance can replicate files to GCP. Verify that direct peering can establish a secure connection between your networks if the Transfer Appliance fails.
  • DVerify that the Transfer Appliance can replicate files to GCP. Verify that Cloud VPN can establish a secure connection between your networks if the Transfer Appliance fails.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Verify that Dedicated Interconnect can replicate files to GCP. Verify that Cloud VPN can establish a secure connection between your networks if Dedicated Interconnect fails.

Explanation

Dedicated Interconnect provides a private physical connection into Google's network. Cloud VPN provides encrypted IPsec connectivity between on premises and a VPC. By spanning multiple Availability Zones / adding redundancy, this option provides the high availability and resilience required.

Showing questions 61–80 of 337 Β· Page 4 of 17