Weekend Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: 70percent

Google Professional-Cloud-Database-Engineer Google Cloud Certified - Professional Cloud Database Engineer Exam Practice Test

Google Cloud Certified - Professional Cloud Database Engineer Questions and Answers

Question 1

Your hotel booking company is expanding into Country A, where personally identifiable information (PII) must comply with regional data residency requirements and audits. You need to isolate customer data in Country A from the rest of the customer data. Youwant to design a multi-tenancy strategy to efficiently manage costs and operations. What should you do?

Options:

A.

Apply a schema data management pattern.

B.

Apply an instance data management pattern.

C.

Apply a table data management pattern.

D.

Apply a database data management pattern.

Question 2

You are managing a Cloud SQL for PostgreSQL instance in Google Cloud. You need to test the high availability of your Cloud SQL instance by performing a failover. You want to use the cloud command.

What should you do?

Options:

A.

Use gcloud sql instances failover .

B.

Use gcloud sql instances failover .

C.

Use gcloud sql instances promote-replica .

D.

Use gcloud sql instances promote-replica .

Question 3

Your organization is running a low-latency reporting application on Microsoft SQL Server. In addition to the database engine, you are using SQL Server Analysis Services (SSAS), SQL Server Reporting Services (SSRS), and SQL Server Integration Services (SSIS) in your on-premises environment. You want to migrate your Microsoft SQL Server database instances to Google Cloud. You need to ensure minimal disruption to the existing architecture during migration. What should you do?

Options:

A.

Migrate to Cloud SQL for SQL Server.

B.

Migrate to Cloud SQL for PostgreSQL.

C.

Migrate to Compute Engine.

D.

Migrate to Google Kubernetes Engine (GKE).

Question 4

You have a non-critical business application running on Google Kubernetes Engine (GKE) in the app-dev VPC. You have created an AllayDB cluster with private Service Access (PSA) and no public IP address in the db-dev VPC. You want your application to securely connect to AllowDB in a cost-effective way. What should you do?

Options:

A.

Set up a high availability VPN between the app-dev and db-dev VPCs. Connect the application directly to AlloyDB.

B.

Connect by using the private IP address of the AlloyDB cluster directly from the application.

C.

Connect by using AlloyDB Auth Proxy installed in the GKE cluster.

D.

Install a SOCKS proxy in a VM in the db-dev VPC. Install AlloyDB Auth Proxy in your GKE cluster, and connect to the AlloyDB cluster through the SOCKS server and port.

Question 5

You are starting a large CSV import into a Cloud SQL for MySQL instance that has many open connections. You checked memory and CPU usage, and sufficient resources are available. You want to follow Google-recommended practices to ensure that the import will not time out. What should you do?

Options:

A.

Close idle connections or restart the instance before beginning the import operation.

B.

Increase the amount of memory allocated to your instance.

C.

Ensure that the service account has the Storage Admin role.

D.

Increase the number of CPUs for the instance to ensure that it can handle the additional import operation.

Question 6

You are configuring a brand new Cloud SQL for PostgreSQL database instance in Google Cloud. Your application team wants you to deploy one primary instance, one standby instance, and one read replica instance. You need to ensure that you are following Google-recommended practices for high availability. What should you do?

Options:

A.

Configure the primary instance in zone A, the standby instance in zone C, and the read replica in zone B, all in the same region.

B.

Configure the primary and standby instances in zone A and the read replica in zone B, all in the same region.

C.

Configure the primary instance in one region, the standby instance in a second region, and the read replica in a third region.

D.

Configure the primary, standby, and read replica instances in zone A, all in the same region.

Question 7

Your company is migrating all legacy applications to Google Cloud. All on-premises applications are using legacy Oracle 12c databases with Oracle Real Application Cluster (RAC) for high availability (HA) and Oracle Data Guard for disaster recovery. You need a solution that requires minimal code changes, provides the same high availability you have today on-premises, and supports a low latency network for migrated legacy applications. What should you do?

Options:

A.

Migrate the databases to Cloud Spanner.

B.

Migrate the databases to Cloud SQL, and enable a standby database.

C.

Migrate the databases to Compute Engine using regional persistent disks.

D.

Migrate the databases to Bare Metal Solution for Oracle.

Question 8

Your organization is running a Firestore-backed Firebase app that serves the same top ten news stories on a daily basis to a large global audience. You want to optimize content delivery while decreasing cost and latency. What should you do?

Options:

A.

Enable serializable isolation in the Firebase app.

B.

Deploy a US multi-region Firestore location.

C.

Build a Firestore bundle, and deploy bundles to Cloud CDN.

D.

Create a Firestore index on the news story date.

Question 9

Your company wants to migrate an Oracle-based application to Google Cloud. The application team currently uses Oracle Recovery Manager (RMAN) to back up the database to tape for long-term retention (LTR). You need a cost-effective backup and restore solution that meets a 2-hour recovery time objective (RTO) and a 15-minute recovery point objective (RPO). What should you do?

Options:

A.

Migrate the Oracle databases to Bare Metal Solution for Oracle, and store backups on tapes on-premises.

B.

Migrate the Oracle databases to Bare Metal Solution for Oracle, and use Actifio to store backup files on Cloud Storage using the Nearline Storage class.

C.

Migrate the Oracle databases to Bare Metal Solution for Oracle, and back up the Oracle databases to Cloud Storage using the Standard Storage class.

D.

Migrate the Oracle databases to Compute Engine, and store backups on tapes on-premises.

Question 10

You are a DBA of Cloud SQL for PostgreSQL. You want the applications to have password-less authentication for read and write access to the database. Which authentication mechanism should you use?

Options:

A.

Use Identity and Access Management (IAM) authentication.

B.

Use Managed Active Directory authentication.

C.

Use Cloud SQL federated queries.

D.

Use PostgreSQL database's built-in authentication.

Question 11

You need to migrate existing databases from Microsoft SQL Server 2016 Standard Edition on a single Windows Server 2019 Datacenter Edition to a single Cloud SQL for SQL Server instance. During the discovery phase of your project, you notice that your on-premises server peaks at around 25,000 read IOPS. You need to ensure that your Cloud SQL instance is sized appropriately to maximize read performance. What should you do?

Options:

A.

Create a SQL Server 2019 Standard on Standard machine type with 4 vCPUs, 15 GB of RAM, and 800 GB of solid-state drive (SSD).

B.

Create a SQL Server 2019 Standard on High Memory machine type with at least 16 vCPUs, 104 GB of RAM, and 200 GB of SSD.

C.

Create a SQL Server 2019 Standard on High Memory machine type with 16 vCPUs, 104 GB of RAM, and 4 TB of SSD.

D.

Create a SQL Server 2019 Enterprise on High Memory machine type with 16 vCPUs, 104 GB of RAM, and 500 GB of SSD.

Question 12

Your company is launching a new globally distributed application with strict requirements for low latency, strong consistency, zero downtime, and high availability (HA). You need to configure a scalable database solution to support anticipated rapid growth and optimal application performance. What should you do?

Options:

A.

Create a Cloud SQL instance in HA mode with a cross-region read replica.

B.

Create an AlloyDB instance in HA mode with a cross-region read replica.

C.

Create a spanner instance across regions for optimal performance.

D.

Implement Bigtable with replication across multiple regions and configure to prioritize data accuracy.

Question 13

You are running a transactional application on Cloud SQL for PostgreSQL in Google Cloud. The database is running in a high availability configuration within one region. You have encountered issues with data and want to restore to the last known pristine version of the database. What should you do?

Options:

A.

Create a clone database from a read replica database, and restore the clone in the same region.

B.

Create a clone database from a read replica database, and restore the clone into a different zone.

C.

Use the Cloud SQL point-in-time recovery (PITR) feature. Restore the copy from two hours ago to a new database instance.

D.

Use the Cloud SQL database import feature. Import last week's dump file from Cloud Storage.

Question 14

You are choosing a new database backend for an existing application. The current database is running PostgreSQL on an on-premises VM and is managed by a database administrator and operations team. The application data is relational and has light traffic. You want to minimize costs and the migration effort for this application. What should you do?

Options:

A.

Migrate the existing database to Firestore.

B.

Migrate the existing database to Cloud SQL for PostgreSQL.

C.

Migrate the existing database to Cloud Spanner.

D.

Migrate the existing database to PostgreSQL running on Compute Engine.

Question 15

You work for a financial services company that wants to use fully managed database services. Traffic volume for your consumer services products has increased annually at a constant rate with occasional spikes around holidays. You frequently need to upgrade the capacity of your database. You want to use Cloud Spanner and include an automated method to increase your hardware capacity to support a higher level of concurrency. What should you do?

Options:

A.

Use linear scaling to implement the Autoscaler-based architecture

B.

Use direct scaling to implement the Autoscaler-based architecture.

C.

Upgrade the Cloud Spanner instance on a periodic basis during the scheduled maintenance window.

D.

Set up alerts that are triggered when Cloud Spanner utilization metrics breach the threshold, and then schedule an upgrade during the scheduled maintenance window.

Question 16

You are configuring a new application that has access to an existing Cloud Spanner database. The new application reads from this database to gather statistics for a dashboard. You want to follow Google-recommended practices when granting Identity and Access Management (IAM) permissions. What should you do?

Options:

A.

Reuse the existing service account that populates this database.

B.

Create a new service account, and grant it the Cloud Spanner Database Admin role.

C.

Create a new service account, and grant it the Cloud Spanner Database Reader role.

D.

Create a new service account, and grant it the spanner.databases.select permission.

Question 17

Your organization is migrating 50 TB Oracle databases to Bare Metal Solution for Oracle. Database backups must be available for quick restore. You also need to have backups available for 5 years. You need to design a cost-effective architecture that meets a recovery time objective (RTO) of 2 hours and recovery point objective (RPO) of 15 minutes. What should you do?

Options:

A.

Create the database on a Bare Metal Solution server with the database running on flash storage.

Keep a local backup copy on all flash storage.

Keep backups older than one day stored in Actifio OnVault storage.

B.

Create the database on a Bare Metal Solution server with the database running on flash storage.

Keep a local backup copy on standard storage.

Keep backups older than one day stored in Actifio OnVault storage.

C.

Create the database on a Bare Metal Solution server with the database running on flash storage.

Keep a local backup copy on standard storage.

Use the Oracle Recovery Manager (RMAN) backup utility to move backups older than one day to a Coldline Storage bucket.

D.

Create the database on a Bare Metal Solution server with the database running on flash storage.

Keep a local backup copy on all flash storage.

Use the Oracle Recovery Manager (RMAN) backup utility to move backups older than one day to an Archive Storage bucket.

Question 18

Your application follows a microservices architecture and uses a single large Cloud SQL instance, which is starting to have performance issues as your application grows. in the Cloud Monitoring dashboard, the CPU utilization looks normal You want to followGoogle-recommended practices to resolve and prevent these performance issues while avoiding any major refactoring. What should you do?

Options:

A.

Use Cloud Spanner instead of Cloud SQL.

B.

Increase the number of CPUs for your instance.

C.

Increase the storage size for the instance.

D.

Use many smaller Cloud SQL instances.

Question 19

You are the database administrator of a Cloud SQL for PostgreSQL instance that has pgaudit disabled. Users are complaining that their queries are taking longer to execute and performance has degraded over the past few months. You need to collect and analyze query performance data to help identity slow-running queries. What should you do?

Options:

A.

View Cloud SQL operations to view historical query information.

B.

White a Logs Explorer query to identify database queries with high execution times.

C.

Review application logs to identify database calls.

D.

Use the Query Insights dashboard to identify high execution times.

Question 20

You released a popular mobile game and are using a 50 TB Cloud Spanner instance to store game data in a PITR-enabled production environment. When you analyzed the game statistics, you realized that some players are exploiting a loophole to gather more points to get on the leaderboard. Another DBA accidentally ran an emergency bugfix script that corrupted some of the data in the production environment. You need to determine the extent of the data corruption and restore the production environment. What should you do? (Choose two.)

Options:

A.

If the corruption is significant, use backup and restore, and specify a recovery timestamp.

B.

If the corruption is significant, perform a stale read and specify a recovery timestamp. Write the results back.

C.

If the corruption is significant, use import and export.

D.

If the corruption is insignificant, use backup and restore, and specify a recovery timestamp.

E.

If the corruption is insignificant, perform a stale read and specify a recovery timestamp. Write the results back.

Question 21

You use Python scripts to generate weekly SQL reports to assess the state of your databases and determine whether you need to reorganize tables or run statistics. You want to automate this report but need to minimize operational costs and overhead. What should you do?

Options:

A.

Create a VM in Compute Engine, and run a cron job.

B.

Create a Cloud Composer instance, and create a directed acyclic graph (DAG).

C.

Create a Cloud Function, and call the Cloud Function using Cloud Scheduler.

D.

Create a Cloud Function, and call the Cloud Function from a Cloud Tasks queue.

Question 22

Your organization has strict policies on tracking rollouts to production and periodically shares this information with external auditors to meet compliance requirements. You need to enable auditing on several Cloud Spanner databases. What should you do?

Options:

A.

Use replication to roll out changes to higher environments.

B.

Use backup and restore to roll out changes to higher environments.

C.

Use Liquibase to roll out changes to higher environments.

D.

Manually capture detailed DBA audit logs when changes are rolled out to higher environments.

Question 23

You are configuring a brand new PostgreSQL database instance in Cloud SQL. Your application team wants to have an optimal and highly available environment with automatic failover to avoid any unplanned outage. What should you do?

Options:

A.

Create one regional Cloud SQL instance with a read replica in another region.

B.

Create one regional Cloud SQL instance in one zone with a standby instance in another zone in the same region.

C.

Create two read-write Cloud SQL instances in two different zones with a standby instance in another region.

D.

Create two read-write Cloud SQL instances in two different regions with a standby instance in another zone.

Question 24

Your company is using Cloud SQL for MySQL with an internal (private) IP address and wants to replicate some tables into BigQuery in near-real time for analytics and machine learning. You need to ensure that replication is fast and reliable and uses Google-managed services. What should you do?

Options:

A.

Develop a custom data replication service to send data into BigQuery.

B.

Use Cloud SQL federated queries.

C.

Use Database Migration Service to replicate tables into BigQuery.

D.

Use Datastream to capture changes, and use Dataflow to write those changes to BigQuery.

Question 25

You are designing a database strategy for a new web application in one region. You need to minimize write latency. What should you do?

Options:

A.

Use Cloud SQL with cross-region replicas.

B.

Use high availability (HA) Cloud SQL with multiple zones.

C.

Use zonal Cloud SQL without high availability (HA).

D.

Use Cloud Spanner in a regional configuration.

Question 26

Your digital-native business runs its database workloads on Cloud SQL. Your website must be globally accessible 24/7. You need to prepare your Cloud SQL instance for high availability (HA). You want to follow Google-recommended practices. What should you do? (Choose two.)

Options:

A.

Set up manual backups.

B.

Create a PostgreSQL database on-premises as the HA option.

C.

Configure single zone availability for automated backups.

D.

Enable point-in-time recovery.

E.

Schedule automated backups.

Question 27

You are evaluating Cloud SQL for PostgreSQL as a possible destination for your on-premises PostgreSQL instances. Geography is becoming increasingly relevant to customer privacy worldwide. Your solution must support data residency requirements and include a strategy to:

configure where data is stored

control where the encryption keys are stored

govern the access to data

What should you do?

Options:

A.

Replicate Cloud SQL databases across different zones.

B.

Create a Cloud SQL for PostgreSQL instance on Google Cloud for the data that does not need to adhere to data residency requirements. Keep the data that must adhere to data residency requirements on-premises. Make application changes to support both databases.

C.

Allow application access to data only if the users are in the same region as the Google Cloud region for the Cloud SQL for PostgreSQL database.

D.

Use features like customer-managed encryption keys (CMEK), VPC Service Controls, and Identity and Access Management (IAM) policies.

Question 28

Your company is developing a global ecommerce website on Google Cloud. Your development team is working on a shopping cart service that is durable and elastically scalable with live traffic. Business disruptions from unplanned downtime are expected to be less than 5 minutes per month. In addition, the application needs to have very low latency writes. You need a data storage solution that has high write throughput and provides 99.99% uptime. What should you do?

Options:

A.

Use Cloud SQL for data storage.

B.

Use Cloud Spanner for data storage.

C.

Use Memorystore for data storage.

D.

Use Bigtable for data storage.

Question 29

You are managing a Cloud SQL for PostgreSQL instance in Google Cloud. You have a primary instance in region 1 and a read replica in region 2. After a failure of region 1, you need to make the Cloud SQL instance available again. You want to minimize data loss and follow Google-recommended practices. What should you do?

Options:

A.

Restore the Cloud SQL instance from the automatic backups in region 3.

B.

Restore the Cloud SQL instance from the automatic backups in another zone in region 1.

C.

Check "Lag Bytes" in the monitoring dashboard for the primary instance in the read replica instance. Check the replication status usingpg_catalog.pg_last_wal_receive_lsn(). Then, fail over to region 2 by promoting the read replica instance.

D.

Check your instance operational log for the automatic failover status. Look for time, type, and status of the operations. If the failover operation is successful, no action is necessary. Otherwise, manually perform gcloud sql instances failover .

Question 30

You are migrating your data center to Google Cloud. You plan to migrate your applications to Compute Engine and your Oracle databases to Bare Metal Solution for Oracle. You must ensure that the applications in different projects can communicate securely and efficiently with the Oracle databases. What should you do?

Options:

A.

Set up a Shared VPC, configure multiple service projects, and create firewall rules.

B.

Set up Serverless VPC Access.

C.

Set up Private Service Connect.

D.

Set up Traffic Director.

Question 31

You need to redesign the architecture of an application that currently uses Cloud SQL for PostgreSQL. The users of the application complain about slow query response times. You want to enhance your application architecture to offer sub-millisecond query latency. What should you do?

Options:

A.

Configure Firestore, and modify your application to offload queries.

B.

Configure Bigtable, and modify your application to offload queries.

C.

Configure Cloud SQL for PostgreSQL read replicas to offload queries.

D.

Configure Memorystore, and modify your application to offload queries.

Question 32

You are designing for a write-heavy application. During testing, you discover that the write workloads are performant in a regional Cloud Spanner instance but slow down byan order of magnitude in a multi-regional instance. You want to make the write workloads faster in a multi-regional instance. What should you do?

Options:

A.

Place the bulk of the read and write workloads closer to the default leader region.

B.

Use staleness of at least 15 seconds.

C.

Add more read-write replicas.

D.

Keep the total CPU utilization under 45% in each region.

Question 33

You are planning to migrate a 10TB relational database from an on-premises environment la Cloud SQL for PostgreSQL. The database contains sensitive customer

Information. You want to follow Google-recommended practices to keep data secure during the migration. What should you do?

Choose 2 answers

Options:

A.

Establish a Private Se-vice Connect connection between your on-premises environment and the Cloud SQL instance

B.

Set up identity Access Management JIAM) roles to restrict access with Cloud SQL with an internal IP address.

C.

Use an external IH address for the Cloud SQL Instance, and configure firewall rules.

D.

Configure Cloud SQL for automatic patching, and enable binary logging.

E.

Leverage Storage Transfer Service with client side encryption.

Question 34

You are choosing a database backend for a new application. The application will ingest data points from IoT sensors. You need to ensure that the application can scale up to millions of requests per second with sub-10ms latency and store up to 100 TB of history. What should you do?

Options:

A.

Use Cloud SQL with read replicas for throughput.

B.

Use Firestore, and rely on automatic serverless scaling.

C.

Use Memorystore for Memcached, and add nodes as necessary to achieve the required throughput.

D.

Use Bigtable, and add nodes as necessary to achieve the required throughput.

Question 35

Your organization works with sensitive data that requires you to manage your own encryption keys. You are working on a project that stores that data in a Cloud SQLdatabase. You need to ensure that stored data is encrypted with your keys. What should you do?

Options:

A.

Export data periodically to a Cloud Storage bucket protected by Customer-Supplied Encryption Keys.

B.

Use Cloud SQL Auth proxy.

C.

Connect to Cloud SQL using a connection that has SSL encryption.

D.

Use customer-managed encryption keys with Cloud SQL.

Question 36

Your customer is running a MySQL database on-premises with read replicas. The nightly incremental backups are expensive and add maintenance overhead. You want to follow Google-recommended practices to migrate the database to Google Cloud, and you need to ensure minimal downtime. What should you do?

Options:

A.

Create a Google Kubernetes Engine (GKE) cluster, install MySQL on the cluster, and then import the dump file.

B.

Use the mysqldump utility to take a backup of the existing on-premises database, and then import it into Cloud SQL.

C.

Create a Compute Engine VM, install MySQL on the VM, and then import the dump file.

D.

Create an external replica, and use Cloud SQL to synchronize the data to the replica.

Question 37

Your organization is running a critical production database on a virtual machine (VM) on Compute Engine. The VM has an ext4-formatted persistent disk for data files. Thedatabase will soon run out of storage space. You need to implement a solution that avoids downtime. What should you do?

Options:

A.

In the Google Cloud Console, increase the size of the persistent disk, and use the resize2fs command to extend the disk.

B.

In the Google Cloud Console, increase the size of the persistent disk, and use the fdisk command to verify that the new space is ready to use

C.

In the Google Cloud Console, create a snapshot of the persistent disk, restore the snapshot to a new larger disk, unmount the old disk, mount the new disk, and restart the database service.

D.

In the Google Cloud Console, create a new persistent disk attached to the VM, and configure the database service to move the files to the new disk.

Question 38

Your application uses Cloud SQL for MySQL. Your users run reports on data that relies on near-real time; however, the additional analytics caused excessive load on the primary database. You created a read replica for the analytics workloads, but now your users are complaining about the lag in data changes and that their reports are still slow.You need to improve the report performance and shorten the lag in data replication without making changes to the current reports. Which two approaches should you implement? (Choose two.)

Options:

A.

Create secondary indexes on the replica.

B.

Create additional read replicas, and partition your analytics users to use different read replicas.

C.

Disable replication on the read replica, and set the flag for parallel replication on the read replica. Re-enable replication and optimize performance by setting flags on the primary instance.

D.

Disable replication on the primary instance, and set the flag for parallel replication on the primary instance. Re-enable replication and optimize performance by setting flags on the read replica.

E.

Move your analytics workloads to BigQuery, and set up a streaming pipeline to move data and update BigQuery.

Question 39

Your DevOps team is using Terraform to deploy applications and Cloud SQL databases. After every new application change is rolled out, the environment is torn down and recreated, and the persistent database layer is lost. You need to prevent the database from being dropped. What should you do?

Options:

A.

Set Terraform deletion_protection to true.

B.

Rerun terraform apply.

C.

Create a read replica.

D.

Use point-in-time-recovery (PITR) to recover the database.

Question 40

Your organization has an existing app that just went viral. The app uses a Cloud SQL for MySQL backend database that is experiencing slow disk performance while using hard disk drives (HDDs). You need to improve performance and reduce disk I/O wait times. What should you do?

Options:

A.

Export the data from the existing instance, and import the data into a new instance with solid-state drives (SSDs).

B.

Edit the instance to change the storage type from HDD to SSD.

C.

Create a high availability (HA) failover instance with SSDs, and perform a failover to the new instance.

D.

Create a read replica of the instance with SSDs, and perform a failover to the new instance

Question 41

Your company wants to migrate its MySQL, PostgreSQL, and Microsoft SQL Server on-premises databases to Google Cloud. You need a solution that provides near-zero downtime, requires no application changes, and supports change data capture (CDC). What should you do?

Options:

A.

Use the native export and import functionality of the source database.

B.

Create a database on Google Cloud, and use database links to perform the migration.

C.

Create a database on Google Cloud, and use Dataflow for database migration.

D.

Use Database Migration Service.