Sign in
Home/Google Cloud/Professional Cloud Database Engineer (Google Cloud)/Free questions

Professional Cloud Database Engineer (Google Cloud) — Free Practice Questions

10 free sample questions from a bank of 131, with the correct answers and explanations. No signup required — start practising right now.

1You are developing a new application on a VM that is on your corporate network. The application will use Java Database Connectivity (JDBC) to connect to Cloud SQL for PostgreSQL. Your Cloud SQL instance is configured with IP address 192.168.3.48, and SSL is disabled. You want to ensure that your application can access your database instance without requiring configuration changes to your database. What should you do?
  • Define a connection string using your Google username and password to point to the external (public) IP address of your Cloud SQL instance.
  • Define a connection string using a database username and password to point to the internal (private) IP address of your Cloud SQL instance.
  • Define a connection string using Cloud SQL Auth proxy configured with a service account to point to the internal (private) IP address of your Cloud SQL instance.
  • Define a connection string using Cloud SQL Auth proxy configured with a service account to point to the external (public) IP address of your Cloud SQL instance.
Answer: C

The short version

C — Auth proxy with a service account to the private IP connects JDBC without DB changes. The proxy carries IAM authentication and encryption over the existing private address, so SSL-disabled instance config stays untouched.

Key concepts in this question

  • JDBC from corporate network: Java app on-prem needing a standard Postgres driver string that resolves to Cloud SQL.
  • Private IP 192 dot 168 dot 3 dot 48: existing internal address that already routes over interconnect or VPN without reconfiguration.
  • SSL disabled: instance state the team must preserve, which makes proxy-provided TLS especially valuable.
  • Cloud SQL Auth proxy: local sidecar that listens for JDBC connections and forwards them securely with IAM authorization.
  • Service account identity: machine credential that the proxy uses to prove who may connect, avoiding embedded DB passwords.

Why C is correct

Pointing JDBC at the Auth proxy with a service account preserves the private IP path the network already supports while adding authentication and encryption outside the database. No Cloud SQL settings change because the proxy handles secure tunneling to the same internal endpoint. Public-IP variants would force network and firewall rework that the stem forbids.

Why the others are wrong

  • A. A Google username and password to the public IP bypasses the private path and introduces public exposure plus config changes.
  • B. A raw database password to the private IP works only without proxy benefits and leaves traffic unencrypted with SSL disabled.
  • D. Proxy to the public IP abandons the working private route and requires exposing the instance publicly for no gain.
  • C. This is the settled correct option and the only no-change private secure path.

PCDBE exam tip

For on-prem JDBC with private IP and no DB changes, choose Auth proxy with service account to the private IP.

2Your 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.)
  • Set up manual backups.
  • Create a PostgreSQL database on-premises as the HA option.
  • Configure single zone availability for automated backups.
  • Enable point-in-time recovery.
  • Schedule automated backups.
Answer: D, E

The short version

D and E — Enable point-in-time recovery and schedule automated backups for Cloud SQL HA readiness. The pair gives restorable history plus log replay that manual or single-zone tactics cannot provide.

Key concepts in this question

  • Global 24-7 website: demand for continuous availability where any data loss or extended restore breaks revenue.
  • High availability preparation: set of managed durability controls that precede enabling regional failover.
  • Automated backups: scheduled full and incremental copies that create the base images for restore and PITR.
  • Point-in-time recovery: log-retained ability to rewind to any second, complementing daily backup granularity.
  • Google-recommended practices: managed backup plus PITR rather than on-prem standby or manual copies.

Why DE is correct

Automated backups establish the restorable baseline on a managed schedule, while PITR retains write-ahead logs so recovery can target the last pristine second. Together they satisfy both durability and granularity pillars of HA preparation for a global site. Manual backups, on-prem Postgres or single-zone backup settings lack automation, precision or cloud-native failover alignment.

Why the others are wrong

  • A. Manual backups depend on operator discipline and miss the automation and retention guarantees the stem requires.
  • B. An on-premises PostgreSQL host is not a Cloud SQL high-availability option and reintroduces data-center dependence.
  • C. Single-zone availability for backups forfeits the regional resilience a 24-7 global site must prepare for.
  • DE. These are the settled correct options and the only automated precise recovery pair.

PCDBE exam tip

For prepare Cloud SQL for HA, pick automated backups plus point-in-time recovery as the two must-haves.

3Your company wants to move to Google Cloud. Your current data center is closing in six months. You are running a large, highly transactional Oracle application footprint on VMWare. You need to design a solution with minimal disruption to the current architecture and provide ease of migration to Google Cloud. What should you do?
  • Migrate applications and Oracle databases to Google Cloud VMware Engine (VMware Engine).
  • Migrate applications and Oracle databases to Compute Engine.
  • Migrate applications to Cloud SQL.
  • Migrate applications and Oracle databases to Google Kubernetes Engine (GKE).
Answer: A

The short version

A — VMware Engine carries large Oracle on VMware to Google Cloud with least disruption. It preserves virtualization, networking and Oracle behavior so the closing data center moves on schedule.

Key concepts in this question

  • Large Oracle on VMware: footprint where apps and databases share virtualized infrastructure, affinity and operational tooling.
  • Six-month data-center exit: time pressure that favors rehosting over refactoring engines or containerizing.
  • Minimal disruption: need to keep architecture, addresses and procedures familiar during the move.
  • VMware Engine: Google-managed VMware stack with HCX migration, NSX networking and vSphere compatibility.
  • Ease of migration: ability to vMotion or HCX-move VMs including Oracle hosts without reinstalling.

Why A is correct

VMware Engine reproduces the on-prem VMware environment in Google Cloud, so both applications and their Oracle databases move as VMs with the same topology. That avoids engine conversion, GKE redesign or Compute Engine rebuilds that would breach the six-month window. It is the only choice that keeps the current architecture intact while exiting the data center.

Why the others are wrong

  • B. Compute Engine rehosts as native VMs but loses VMware constructs and tooling, adding conversion work for a VMware-heavy estate.
  • C. Moving apps to Cloud SQL implies an Oracle-to-Postgres or MySQL engine change, the opposite of minimal disruption.
  • D. GKE containerization demands application refactoring and new Oracle handling that cannot fit a rapid lift.
  • A. This is the settled correct option and the only like-for-like VMware landing zone.

PCDBE exam tip

For Oracle on VMware needing minimal disruption on a tight exit, choose VMware Engine as the intact landing zone.

4Your customer has a global chat application that uses a multi-regional Cloud Spanner instance. The application has recently experienced degraded performance after a new version of the application was launched. Your customer asked you for assistance. During initial troubleshooting, you observed high read latency. What should you do?
  • Use query parameters to speed up frequently executed queries.
  • Change the Cloud Spanner configuration from multi-region to single region.
  • Use SQL statements to analyze SPANNER_SYS.READ_STATS* tables.
  • Use SQL statements to analyze SPANNER_SYS.QUERY_STATS* tables.
Answer: C

The short version

C — READ_STATS tables diagnose high read latency on multi-regional Spanner. They break down row reads by table and split to reveal hotspots and stale scans after the new release.

Key concepts in this question

  • Multi-regional Spanner reads: globally replicated serving where routing and replica choice affect observed latency.
  • Post-release degradation: symptom tied to changed access patterns rather than regional failure.
  • SPANNER_SYS dot READ_STATS: introspection tables reporting read counts, latency and scanned rows per table and replica.
  • Versus QUERY_STATS: tables focused on query execution shapes and optimizer behavior rather than storage read distribution.
  • Targeted triage: need to confirm whether latency comes from hotspots, full scans or replica imbalance before tuning.

Why C is correct

High read latency after a code push most often reflects new full-table scans or skewed key access, which READ_STATS surfaces directly with per-table read and latency breakdowns. That lets the team pinpoint the offending tables and key ranges introduced by the release. QUERY_STATS helps query text tuning, while parameter or region-change guesses act without evidence.

Why the others are wrong

  • A. Query parameters help plan reuse but do not diagnose whether reads are skewed or scanning too many rows.
  • B. Dropping from multi-region to single region sacrifices availability and latency for distant users without fixing the new access pattern.
  • D. QUERY_STATS analyzes query execution rather than storage read distribution that explains replica-level read latency.
  • C. This is the settled correct option and the only read-distribution diagnostic.

PCDBE exam tip

For Spanner high read latency, inspect SPANNER_SYS READ_STATS first, and save QUERY_STATS for query-shape tuning.

5Your company has PostgreSQL databases on-premises and on Amazon Web Services (AWS). You are planning multiple database migrations to Cloud SQL in an effort to reduce costs and downtime. You want to follow Google-recommended practices and use Google native data migration tools. You also want to closely monitor the migrations as part of the cutover strategy. What should you do?
  • Use Database Migration Service to migrate all databases to Cloud SQL.
  • Use Database Migration Service for one-time migrations, and use third-party or partner tools for change data capture (CDC) style migrations.
  • Use data replication tools and CDC tools to enable migration.
  • Use a combination of Database Migration Service and partner tools to support the data migration strategy.
Answer: A

The short version

A — Database Migration Service alone migrates on-prem and AWS PostgreSQL natively with monitoring. One managed CDC pipeline covers all sources for cutover without third-party replication sprawl.

Key concepts in this question

  • PostgreSQL on-prem and on AWS: heterogeneous origins that share the same engine but live in different networks.
  • Google-native tooling: preference for first-party migration with support and Cloud Console visibility.
  • Cost and downtime goals: need for convergent replication rather than repeated offline dumps.
  • Cutover monitoring: requirement to track lag, throughput and validation before switching primaries.
  • Single-service simplicity: avoiding a matrix of one-time plus partner CDC tools when one service handles both.

Why A is correct

DMS supports PostgreSQL from both on-prem and other clouds with initial load plus WAL-based CDC and built-in monitoring for lag and errors. Using it for all databases standardizes connectivity, validation and promotion in one workflow. Splitting between one-time DMS and partner CDC fragments operations and forfeits the unified cutover dashboard the stem wants.

Why the others are wrong

  • B. Reserving DMS for one-time loads while delegating CDC to third parties doubles tooling and loses native convergent monitoring.
  • C. Generic replication plus CDC tools add licensing and support burden when a Google-native path already covers PostgreSQL.
  • D. Mixing DMS with partner tools for the same engine adds handoffs and cost with no capability the single service lacks.
  • A. This is the settled correct option and the only unified native monitored path.

PCDBE exam tip

For multiple PostgreSQL sources to Cloud SQL with native monitoring, use DMS for all moves, not mixed tooling.

6You are setting up a Bare Metal Solution environment. You need to update the operating system to the latest version. You need to connect the Bare Metal Solution environment to the internet so you can receive software updates. What should you do?
  • Setup a static external IP address in your VPC network.
  • Set up bring your own IP (BYOIP) in your VPC.
  • Set up a Cloud NAT gateway on the Compute Engine VM.
  • Set up Cloud NAT service.
Answer: C

The short version

C — A Cloud NAT gateway on the Compute Engine VM path gives Bare Metal outbound internet for updates. It supplies managed address translation for OS patch egress without exposing hosts directly.

Key concepts in this question

  • Bare Metal Solution isolation: Oracle and system hosts in a peered extension without default internet egress.
  • OS updates need: requirement for outbound HTTPS to vendor repositories with no inbound exposure.
  • Cloud NAT gateway: managed translation that lets private hosts share ephemeral public egress for updates.
  • Compute Engine VM adjacency: jump or service VM in the connected VPC that anchors the NAT path per the settled design.
  • Least-exposure egress: pattern of allowing initiated outbound flows while denying unsolicited inbound internet.

Why C is correct

The settled key designates the NAT gateway associated with the Compute Engine VM path as the update route for the Bare Metal environment. It provides outbound translation so package managers can reach the internet while hosts keep private addresses. Static public IPs, BYOIP or generic Cloud NAT service labels do not match the designated gateway arrangement in this stem.

Why the others are wrong

  • A. A static external IP on the VPC assigns direct public identity rather than the managed NAT egress the key specifies.
  • B. BYOIP brings address space for public serving and does not by itself create the NAT update path.
  • D. A generic Cloud NAT service label misses the settled VM-anchored gateway topology for this Bare Metal egress.
  • C. This is the settled correct option and the designated update egress.

PCDBE exam tip

For Bare Metal OS updates needing internet, select the settled NAT gateway on the Compute Engine VM path.

7Your organization is running a MySQL workload in Cloud SQL. Suddenly you see a degradation in database performance. You need to identify the root cause of the performance degradation. What should you do?
  • Use Logs Explorer to analyze log data.
  • Use Cloud Monitoring to monitor CPU, memory, and storage utilization metrics.
  • Use Error Reporting to count, analyze, and aggregate the data.
  • Use Cloud Debugger to inspect the state of an application.
Answer: B

The short version

B — Cloud Monitoring of CPU, memory and storage finds the MySQL degradation cause. Infrastructure metrics reveal saturation or growth trends that logs, error buckets or debuggers cannot attribute.

Key concepts in this question

  • Sudden MySQL slowdown: symptom that often traces to CPU steal, memory pressure or disk fill rather than code bugs.
  • Cloud Monitoring metrics: time-series for utilization, IOPS and capacity that correlate slowdown onset with resource exhaustion.
  • Root-cause workflow: compare degradation timestamp against saturation signals before tuning queries or scaling.
  • Logs versus metrics: distinction between event text and quantitative saturation that decides scaling action.
  • Managed triage speed: using built-in Cloud SQL dashboards for fastest signal without agents.

Why B is correct

CPU, memory and storage utilization directly show whether the MySQL host is throttled, swapping or filling, which are the most common sudden-degradation drivers. Monitoring charts let the team link the slowdown minute to a saturated resource and then resize or optimize accordingly. Log analysis, error grouping or live debugging miss the saturation evidence that decides the fix.

Why the others are wrong

  • A. Logs Explorer surfaces event text but does not quantify CPU or memory saturation driving database slowness.
  • C. Error Reporting counts exceptions and is blind to resource exhaustion without errors.
  • D. Cloud Debugger inspects application code state, not Cloud SQL host resource pressure.
  • B. This is the settled correct option and the only saturation-telemetry path.

PCDBE exam tip

For sudden Cloud SQL performance dip, check Monitoring CPU plus memory plus storage before logs or debugger.

8You work for a large retail and ecommerce company that is starting to extend their business globally. Your company plans to migrate to Google Cloud. You want to use platforms that will scale easily, handle transactions with the least amount of latency, and provide a reliable customer experience. You need a storage layer for sales transactions and current inventory levels. You want to retain the same relational schema that your existing platform uses. What should you do?
  • Store your data in Firestore in a multi-region location, and place your compute resources in one of the constituent regions.
  • Deploy Cloud Spanner using a multi-region instance, and place your compute resources close to the default leader region.
  • Build an in-memory cache in Memorystore, and deploy to the specific geographic regions where your application resides.
  • Deploy a Bigtable instance with a cluster in one region and a replica cluster in another geographic region.
Answer: B

The short version

B — Multi-region Spanner near the leader region scales global sales with least latency on the same schema. It keeps relational transactions and inventory consistency worldwide without rewrites.

Key concepts in this question

  • Global retail expansion: growth from regional to worldwide with transactions and inventory that must stay correct.
  • Same relational schema: constraint that favors standard SQL with joins and ACID over document or key-value remodels.
  • Least latency: need to serve reads and commits close to users and leaders rather than hairpinning to one region.
  • Multi-region instance: Spanner deployment with synchronous replicas on several continents and a default leader near compute.
  • Reliable customer experience: combination of availability, consistency and speed during worldwide scale.

Why B is correct

Multi-region Spanner preserves the existing relational model while adding synchronous global replicas that serve local reads and commit efficiently near the leader region. Placing compute close to that leader minimizes commit round trips for sales and inventory. Firestore changes the model, Memorystore is not durable relational storage, and Bigtable drops relational transactions.

Why the others are wrong

  • A. Firestore multi-region is document-oriented and would force a schema and transaction rewrite for sales integrity.
  • C. Memorystore is an ephemeral cache and cannot durably store sales and inventory with relational guarantees.
  • D. Bigtable with cross-region clusters scales keys but lacks relational schema and multi-row transactions.
  • B. This is the settled correct option and the only same-schema global low-latency store.

PCDBE exam tip

For global retail needing same relational schema with least latency, pick multi-region Spanner near the leader.

9You host an application in Google Cloud. The application is located in a single region and uses Cloud SQL for transactional data. Most of your users are located in the same time zone and expect the application to be available 7 days a week, from 6 AM to 10 PM. You want to ensure regular maintenance updates to your Cloud SQL instance without creating downtime for your users. What should you do?
  • Configure a maintenance window during a period when no users will be on the system. Control the order of update by setting non-production instances to earlier and production instances to later.
  • Create your database with one primary node and one read replica in the region.
  • Enable maintenance notifications for users, and reschedule maintenance activities to a specific time after notifications have been sent.
  • Configure your Cloud SQL instance with high availability enabled.
Answer: A

The short version

A — Off-hours window with non-prod first ordering gives patching without user downtime. Night maintenance plus staged rollout lets 6 AM to 10 PM users operate while updates land safely.

Key concepts in this question

  • Single-region Cloud SQL: transactional host serving a time-bounded user base with predictable quiet hours.
  • Six AM to ten PM availability: business window that leaves overnight hours free for disruptive work.
  • Maintenance window timing: selection of a no-user period so restarts never overlap with traffic.
  • Update order control: setting non-production before production so bad patches surface early and production moves later.
  • Regular updates without downtime: goal of staying patched while preserving daytime service levels.

Why A is correct

Configuring the window when no users are present ensures Cloud SQL restarts occur overnight rather than during the 6-to-10 service day. Controlling order by moving non-production earlier and production later adds a canary that further protects users. Replica, notification or HA-only options either add topology without timing control or merely announce rather than avoid daytime hits.

Why the others are wrong

  • B. A primary plus read replica adds read scale but does not reschedule managed maintenance away from user hours.
  • C. Notifications and rescheduling are reactive messaging, not a standing off-hours window with staged ordering.
  • D. High availability speeds failover but does not by itself confine patch restarts to the overnight quiet period.
  • A. This is the settled correct option and the only timing plus ordering control.

PCDBE exam tip

For 6 AM to 10 PM users needing no-downtime patching, set an overnight window with non-prod before prod.

10Your team recently released a new version of a highly consumed application to accommodate additional user traffic. Shortly after the release, you received an alert from your production monitoring team that there is consistently high replication lag between your primary instance and the read replicas of your Cloud SQL for MySQL instances. You need to resolve the replication lag. What should you do?
  • Identify and optimize slow running queries, or set parallel replication flags.
  • Stop all running queries, and re-create the replicas.
  • Edit the primary instance to upgrade to a larger disk, and increase vCPU count.
  • Edit the primary instance to add additional memory.
Answer: A

The short version

A — Optimize slow queries or set parallel replication flags to clear MySQL lag. High lag after a traffic-heavy release usually means long transactions block appliers, so tuning plus parallelism restores flow.

Key concepts in this question

  • Replication lag: delay between primary commits and replica applies that grows when appliers cannot keep pace.
  • Post-release surge: new code that adds heavy writes or long analytics that choke single-threaded apply.
  • Slow-query optimization: shortening transactions and adding indexes so the replication stream has less work per event.
  • Parallel replication flags: MySQL settings that let independent schemas or transactions apply concurrently.
  • Safe remediation: fix that preserves replicas and data rather than rebuilding topology blindly.

Why A is correct

Identifying and tuning the slow statements that arrived with the release directly reduces the apply backlog, while parallel replication lets independent work proceed concurrently on replicas. This two-pronged fix addresses the usual lag root without destroying replicas or overprovisioning the primary. Stopping queries, recreating replicas or upsizing disks treats symptoms rather than apply throughput.

Why the others are wrong

  • B. Stopping queries and recreating replicas discards a healthy topology and causes new initial-sync lag without fixing slow SQL.
  • C. A larger primary disk helps storage-bound primaries but does not accelerate replica apply when SQL is the bottleneck.
  • D. More primary memory aids caching on the writer but leaves single-threaded replica apply constrained.
  • A. This is the settled correct option and the only apply-throughput remedy.

PCDBE exam tip

For Cloud SQL MySQL replica lag after a release, tune slow queries and enable parallel replication flags.

Want the full bank of 131 questions for Professional Cloud Database Engineer (Google Cloud)? See all practice exams.